7 Answers, 1 is accepted
I am also using the datasource as a property, when binding I do not get the values in the detail session. Can you share your experience.
Regards,
Saravanan.R
help me.
This is a general problem, so please elaborate further on your exact scenario. In the concrete case the problem is in the way the datasource is set.
Private Sub Summary_ItemDataBinding(....)
Me.DataSource = mSummaryData
End Sub
Private Sub Summary_ItemDataBinding(....)
DirectCast(sender, Telerik.Reporting.Processing.Report).DataSource= _
mSummaryData
End Sub
Check out the following help articles:
Report Life Cycle
Understanding Events
Generally speaking our suggestion is to use our declarative DataSource components (ObjectDataSource) that we have introduced in Q1 2010. They are optimized for performance and no coding is required.
Greetings,
Peter
the Telerik team
Hello Peter,
I am working on a asp.net application. I am trying to populate the report using the datasource. I am able to pass the values from 1 asp page to another only using Session or Cookies, when I try using the property it does not pass the value to other page or class file. The session or cookies work for only asp.net pages.
The “AlarmValues” is a class that contains “GetAlarmInformation” (same as example) this function is a list from which the values are passed to the report to populate. “EntityListDataSource” is the source of information this value populates when bound to data grid.
Aspx page:
AlarmValues alrmRpt = new AlarmValues();
alrmRpt.TestDBValue = EntityListDataSource;
alrmRpt.ProptotNumOfAlarms = totNumOfAlarms;
AlarmValue Class:
private UIEntityList DBValueToPop;
public UIEntityList TestDBValue
{
get
{
return DBValueToPop;
}
set
{
if (value != null)
{
DBValueToPop = value;
GetAlarmInformation();
}
}
}
The report populates the values with the uncommented lines which are static values if we see for the commented lines “DBValueToPop” contains values from where the values are to be populated. I had checked and it says that “DBValueToPop” does not contain any value since values are not passed through the property.
public List<AlarmInfo> GetAlarmInformation()
{
List<AlarmInfo> AlarmValue = new List<AlarmInfo>();
//foreach (InitiatedAlarmUIEntity entity in DBValueToPop)
//{
AlarmValue.Add(new AlarmInfo()
{
//StartTime = Convert.ToString(entity.StartTime),
//StopTime = Convert.ToString(entity.StopTime),
//AlarmCount = Convert.ToString(entity.AlarmCount),
StartTime = Convert.ToString(1),
StopTime = Convert.ToString(AssigntotNumOfAlarms),
AlarmCount = Convert.ToString(3)
});
//}
return AlarmValue;
}
I am using object datasource. My doubt is that is the “AlarmValue” class gets created new when the report calls it and I need to supply values only as it calls since in the example the query and the connection is passed here.
Reviewing the provided code snippets we are unable to find the cause for the unexpected behavior you have reported. We will appreciate if you open a support ticket and send us a runnable sample application that exhibits the issue. Once we debug it locally we will be able to advise you further.
Regards,Peter
the Telerik team
I have attached the demo web application as per your request. Below is the ticket number.
Your ticket ID is: 387474
Thanks for the help.Regards,
Saravanan