Symptom
I am porting our integration with CR from the old COM based component to CR .Net. I'm using the latest version ((v.13.0.13.1597) for Visual Studio.
Our reports contain BLOB fields which are used throughout the sections, including repeating Details sections. Our database stores the desired width, height, and position of the BLOB field. For convenience, we add the width/height/position database fields as suppressed fields in the report so that we can easily access the values at runtime.
In our existing COM implementation we hook into the ISectionFormat event for each section that contains a BLOB field, and then when these events fire we iterate through the ReportObjects in the section to locate our dimension/position fields by name, something like...
IReportObjectPtr l_ReportObjectPtr = pReport->GetSections()->Item[ sectionNumber ]->GetReportObjects()->Item[ reportObjectIndex ];
if(l_ReportObjectPtr->Kind == crFieldObject )
{
l_FieldObject = l_ReportObjectPtr;
if( l_FieldObject->Name.GetBSTR() == HEIGHT_FIELD_NAME)
m_lfImageHeight = l_FieldObject->Value;
}
Once we have the values, we then again iterate through the ReportObjects in the Section that triggered the event to find the BLOB field and set the width/height/top/left values on the fieldObject accordingly.
How do I achieve this with the .NET SDK as the FieldObject->Value is no longer available?
Read more...
Environment
- Crystal Reports XI R2 RDC component
- Crystal Reports for Visual Studio
Product
Keywords
KBA , BI-RA-CR-SDK , SDK related, including Java/.NET etc. , Problem
About this page
This is a preview of a SAP Knowledge Base Article. Click more to access the full version on SAP for Me (Login required).Search for additional results
Visit SAP Support Portal's SAP Notes and KBA Search.