Skip to main content

Knowledge Base

Go Search
Home > Support > Knowledge Base > Pages > 7150.aspx  

Specifying the correct value for the DwpDataEncoded property on Add Web Part task 
Category: Info 
Applies to: Kivati Studio 

This article describes how to determine the correct setting for the DwpDataEncoded property on the Add Web Part task.

Details

The DwpDataEncoded property on the Add Web Part task enables you to specify web part DWP data as either a raw string or a Base64-encoded string. The value you should set for this property depends on the format of the data in the DwpData property.

  • If the value of the DwpData is a Base64-encoded string, set DwpDataEncoded to “True”.
  • If the value of the DwpData property is a normal, non-Base64-encoded string, set
    DwpDataEncoded to “false”.

To Base64-encode a string, you can use the following C# method:

public static string ConvertToBase64(string s)
{
 byte[] sBytes = Encoding.Default.GetBytes(s);
 return Convert.ToBase64String(sBytes);
}

More Information

The SharePoint SDK contains additional information about creating and adding web parts that may be helpful to you.

Last update: 5/19/2008 
Copyright 2000-2008 Kivati Software, LLC.
Home| Support| Terms of Use| Privacy| Legal