This is a migrated thread and some comments may be shown as answers.

Problem in ActiveRegion.ToolTip

3 Answers 76 Views
Chart (Obsolete)
This is a migrated thread and some comments may be shown as answers.
Arun
Top achievements
Rank 1
Arun asked on 20 Aug 2008, 01:30 PM
Hello
           I am using Telerik Reporting Q1 2008 , I have Created a RadChart when i try to set ToolTip For an  Active Region it shows "Object reference is not set to instance of an Object". 

The Code have used in ItemDataBound is..

Telerik.Reporting.Charting.

ChartSeriesItem chartseries = sender as Telerik.Reporting.Charting.ChartSeriesItem;

chartseries.ActiveRegion.Tooltip = dsGraph.Tables[0].Columns[0].ColumnName;

Pls Kindly help me..

3 Answers, 1 is accepted

Sort by
0
Ves
Telerik team
answered on 21 Aug 2008, 07:24 AM
Hello Arun,

Please use e.SeriesItem.ActiveRegion.Toolip as shown in this online example.

Kind regards,
Ves
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
0
Arun
Top achievements
Rank 1
answered on 21 Aug 2008, 09:13 AM
Hello
             As i said am using Telerik Reporting Q1 2008 . in that ItemBound doesn't have   Telerik.Charting.ChartItemDataBoundEventArgs e. so have cretaed as .         

Telerik.Reporting.Charting.

ChartSeriesItem obj....

    The Code used to Populate RadChart....

    .

private void Rchart3_NeedDataSource(object sender, EventArgs e)

{

this.Rchart3.Series.Clear();

Telerik.Reporting.Charting.

ChartSeries cs = new Telerik.Reporting.Charting.ChartSeries();

cs.Type = Telerik.Reporting.Charting.

ChartSeriesType.Bar;

this.Rchart3.Series.Add(cs);

int intDoc_Tot = 0;

int intVisit_Tot = 0;

int intNonVist_Tot = 0;

strQry =

"select count(doctor_name) As Visit_Doc from tbl_SFA_DCR_Doctor_Visit WHERE User_Code = 'USC00000017' AND DCR_Actual_Date BETWEEN '08/01/2008' AND '08/19/2008'and doctor_name in(select doctor_name AS Total_Doc from tbl_SFA_Doctor_master dm,tbl_sfa_speciality_master sm where sm.speciality_code=dm.speciality_code and region_code in (Select Region_Code from tbl_SFA_User_Region_Mapping where User_Code='USC00000017') and doctor_status='1')";

strQry2 =

"select COUNT(doctor_name) AS Total_Doc from tbl_SFA_Doctor_master dm,tbl_sfa_speciality_master sm where sm.speciality_code=dm.speciality_code and region_code in (Select Region_Code from tbl_SFA_User_Region_Mapping where User_Code='USC00000017') and doctor_status='1'";

strQry3 =

"select count(doctor_name) As Non_Visit_Doc from tbl_SFA_DCR_Doctor_Visit WHERE User_Code = 'USC00000017' AND DCR_Actual_Date BETWEEN '08/01/2008' AND '08/19/2008'and doctor_name not in(select doctor_name AS Total_Doc from tbl_SFA_Doctor_master dm,tbl_sfa_speciality_master sm where sm.speciality_code=dm.speciality_code and region_code in (Select Region_Code from tbl_SFA_User_Region_Mapping where User_Code='USC00000017') and doctor_status='1')";

strQry4 =

"";

strQry5 =

"";

strQry6 =

"";

Telerik.Reporting.Processing.

Chart chart = sender as Telerik.Reporting.Processing.Chart;

dsDoctors1 =

new DataSet();

dsGraph =

new DataSet();

DataTable dt = new DataTable("DocVisitDetails");

DataColumn dcDocTot = new DataColumn("DoctorTott");

dcDocTot.DataType = System.

Type.GetType("System.String");

DataColumn dcVistTot = new DataColumn("VisitDoc");

dcVistTot.DataType = System.

Type.GetType("System.String");

DataColumn dcNonVistTot = new DataColumn("NonVisitDoc");

dcVistTot.DataType = System.

Type.GetType("System.String");

dt.Columns.Add(dcDocTot);

dt.Columns.Add(dcVistTot);

dt.Columns.Add(dcNonVistTot);

DataRow dr = dt.NewRow();

dsDoctors1 = objQry.getMultipleDataSets(strQry, strQry2, strQry3, strQry4, strQry5, strQry6);

intDoc_Tot =

int.Parse(dsDoctors1.Tables[0].Rows[0][0].ToString());

intVisit_Tot =

int.Parse(dsDoctors1.Tables[1].Rows[0][0].ToString());

intNonVist_Tot =

int.Parse(dsDoctors1.Tables[2].Rows[0][0].ToString());

dr[

"DoctorTott"] = intDoc_Tot;

dr[

"VisitDoc"] = intVisit_Tot;

dr[

"NonVisitDoc"] = intNonVist_Tot;

dt.Rows.Add(dr);

dsGraph.Tables.Add(dt);

chart.DataSource = dsGraph.Tables[0];

}

// Here is the Code to set Tooltip.

private void Rchart3_ItemDataBound(object sender, EventArgs e)

{

Telerik.Reporting.Charting.

ChartSeriesItem csi = new Telerik.Reporting.Charting.ChartSeriesItem();

csi.ActiveRegion.Tooltip = dsGraph.Tables[0].Columns[0].ColumnName;

}

Kindly Help me..

0
Steve
Telerik team
answered on 21 Aug 2008, 01:51 PM
Hello Arun,

Unfortunately as noted in the "Known limitations" forum article, currently we do not support interactive reports, which are required in order to create/use ActiveRegions and DrillDown charts.

This functionality is in our features list and it would be considered for implementation for a subsequent version of our Reporting offering.

Please excuse us for the inconvenience.

Greetings,
Steve
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
Tags
Chart (Obsolete)
Asked by
Arun
Top achievements
Rank 1
Answers by
Ves
Telerik team
Arun
Top achievements
Rank 1
Steve
Telerik team
Share this question
or