private void MySubReport_NeedDataSource(object sender, EventArgs e) |
{ |
Processing.Report report = (Processing.Report)sender; |
Processing.IDataObject dataObj = (Processing.IDataObject)report.DataObject; |
MyClass myObj = dataObj.RawData as MyClass; |
... |
} |
In Q1 raw data returns null. Is there a way to cast MyClass or is my access restricted to String s = dataObj["valName"]; ?
Thanks
Private Sub moduleIDGroupHeader_ItemDataBound(ByVal sender As Object, ByVal e As System.EventArgs) Handles moduleIDGroupHeader.ItemDataBound |
Dim Group As Telerik.Reporting.Processing.GroupSection = DirectCast(sender, Telerik.Reporting.Processing.GroupSection) |
Dim txtTitle As Telerik.Reporting.Processing.TextBox = DirectCast(Group.ChildElements.Find("txtDMTitle", True)(0), Telerik.Reporting.Processing.TextBox) |
Dim txtDescription As Telerik.Reporting.Processing.TextBox = DirectCast(Group.ChildElements.Find("txtDMDescription", True)(0), Telerik.Reporting.Processing.TextBox) |
Try |
' Dim row As System.Data.DataRow = DirectCast(Group.DataObject.RawData, System.Data.DataRow) |
Dim row As System.Data.DataRow = DirectCast(Group.DataObject.RawData, System.Data.DataRow) |
txtDescription.Visible = row("DMPDescription") |
txtTitle.Visible = row("DMPTitle") |
txtTitle.Style.Color = System.Drawing.Color.FromArgb(28, 51, 97) |
Catch ex As Exception |
Stop |
End Try |
private void SummarySubReport_ItemDataBinding(object sender, EventArgs e)
{
DataView dv = new DataView(m_data, "LetterBatchId = 491",
null, DataViewRowState.CurrentRows);
Telerik.Reporting.Processing.
SubReport subReport = (Telerik.Reporting.Processing.SubReport)sender;
subReport.InnerReport.DataSource = dv;
}
After updating to 2010 Q1 the innerReport of the subReport is null.
Why has this changed and how can I get this working again?
Private Sub Table1_NeedDataSource(ByVal sender As Object, ByVal e As System.EventArgs) Handles Table1.NeedDataSource |
Dim tab1 As Telerik.Reporting.Processing.Table = DirectCast(sender, Telerik.Reporting.Processing.Table) |
Dim idata1 As Telerik.Reporting.Processing.IDataObject = DirectCast(tab1.DataObject, Telerik.Reporting.Processing.IDataObject) |
Dim obj1 As myobject = DirectCast(idata1.RawData, myobject) |
' |
tab1.DataSource = obj1 |
End Sub |
UPDATE: Looks like this is already reported as issue 1318 and I see a workaround another post on this same issue. I will try the workaround until there is a better method.