Search results
PDF

Breaking Changes

When you upgrade from previous versions of Bold Reports to 2.2.23, there are few breaking changes. The following section explains the breaking changes for Bold Reports version 2.2.23.

Designer resource read and write API

The resource write and read API’s in IReportDesignerController are modified to simplify the resource write and read actions with Bold Report Designer.

Below are the new API details tabulated against old API’s.

Old API New API Description
UploadFile SetData Writes the designer resource into storage location.
GetFilePath GetData Reads the designer resource from storage location.
GetFiles
GetFile

Parameters

SetData

Parameter Name Type Description
key string Bold report designer unique token.
itemId string Unique id of designer resource.
itemData object
Property Name Type Description
Data byte array Gets the resource data as byte array. To write an external resource into storage location, pass the resource data in this property.
PostedFile HttpPostedFile Gets the uploaded resource data as `HttpPostedFile`. The resource data uploaded within report designer will be received in this property.
Gets the resource data.
errorMessage string Returns the error message, if the write action is failed.

GetData

Parameter Name Types Description
key string Bold report designer unique token.
itemId string Unique id of designer resource.

Return Type

API Name Return Type
SetData boolean
GetData object
Property Name Type Description
Data byte array Contains the requested resource data as byte array.
errorMessage string Returns the error message, if the read action is failed.

Code snippet

Old snippet New snippet
UploadFile
public bool UploadFile(System.Web.HttpPostedFile httpPostedFile)
{
    //Implement resource write actions
}
SetData
[NonAction]
public bool SetData(string key, string itemId, ItemInfo itemData, out string errorMessage)
{
     //Implement resource write actions
}
GetFiles
public List<FileModel> GetFiles(FileType fileType)
{
    //Implement resource read actions
}
GetData
[NonAction]
public ResourceInfo GetData(string key, string itemId)
{
    //Implement resource read actions
}
GetFilePath
[NonAction]
public string GetFilePath(string fileName)
{
   //Implement actions to get file path
}
GetFile
public FileModel GetFile(string filename, bool isOverride)
{
    //Implement resource read actions
}