Telerik Forums
Reporting Forum
1 answer
83 views
I have inherited a database where all data is retrieved using Select stored procedures. These have been mapped to functions in a linq to sql model, but when linking up to a Report I don't get any data back. 

I tried to follow the example given in this thread, using an objectdatasource but it still will not work: 
http://www.telerik.com/community/forums/reporting/telerik-reporting/linq-in-an-object-data-source.aspx

The code in my business logic class is:

 

public class BLL
    {
        public static IEnumerable<spGetPackages> GetPackages()
        {
            TardisDataContext context = new TardisDataContext();
            ISingleResult<spGetPackagesResult> result = context.spGetPackages();
            List<spGetPackagesResult> returnlist = result.ToList();
            return returnlist;
        }
    }



In my Report.Designer.cs class I have the following:

//
            // objectDataSource1
            //
            this.objectDataSource1.DataMember = "GetPackages";
            this.objectDataSource1.DataSource = typeof(BLL);
            this.objectDataSource1.Name = "objectDataSource1";


I know the function is working fine as I can retrieve data through a GridView. I think I read a comment somewhere that this method might not work with stored procedures? Where am I going wrong?

Peter
Telerik team
 answered on 11 Jun 2013
2 answers
129 views
I would like to create a pie chart just like the one here: http://demos.telerik.com/reporting/product-line-sales/demo.aspx
However, disappointingly, the video tutorial decided to skip the pie chart.

I want to display a pie chart with ProductName listed on the series, while Quantity is displayed on the chart. I am using a sqldatasource.

This is a sample of my data:

===============================
ProductName                      Quantity
===============================
Crips                                     12
Coke                                      7
Candy Bar                              57

I've got so far as displaying the chart and listing ProductName on legend. However, instead of having the Quantity displayed on the chart like in the demo sample above, the ProductName was displayed instead.

This is the code for my chart:

this.chart3.BitmapResolution = 96F;
this.chart3.ChartTitle.Appearance.Visible = false;
this.chart3.ChartTitle.Visible = false;
this.chart3.DataSource = this.sqlDataSource1;
this.chart3.DefaultType = Telerik.Reporting.Charting.ChartSeriesType.Pie;
this.chart3.ImageFormat = System.Drawing.Imaging.ImageFormat.Emf;
this.chart3.IntelligentLabelsEnabled = true;
this.chart3.Legend.Appearance.Border.Visible = false;
this.chart3.Location = new Telerik.Reporting.Drawing.PointU(Telerik.Reporting.Drawing.Unit.Inch(0.1000000610947609D), Telerik.Reporting.Drawing.Unit.Inch(0.20000012218952179D));
this.chart3.Name = "chart3";
this.chart3.PlotArea.XAxis.MinValue = 1D;
chartSeries1.Appearance.LegendDisplayMode = Telerik.Reporting.Charting.ChartSeriesLegendDisplayMode.ItemLabels;
chartSeries1.DataLabelsColumn = "ProductName";
chartSeries1.DataYColumn = "Quantity";
chartSeries1.Name = "Series 1";
chartSeries1.Type = Telerik.Reporting.Charting.ChartSeriesType.Pie;
this.chart3.Series.AddRange(new Telerik.Reporting.Charting.ChartSeries[] {
chartSeries1});
this.chart3.Size = new Telerik.Reporting.Drawing.SizeU(Telerik.Reporting.Drawing.Unit.Inch(5.0000004768371582D), Telerik.Reporting.Drawing.Unit.Inch(2.8999998569488525D));


Can anyone tell me how to produce the pie chart like the one in the demo sample?

I refuse to believe that I'll have to data bind the chart to generic object list as mentioned by the last reply in this thread (http://www.telerik.com/community/forums/reporting/telerik-reporting/pie-chart-with-value-displayed.aspx) just to achieve this simple functionality.

Thanks.
Iris
Top achievements
Rank 1
 answered on 11 Jun 2013
1 answer
91 views
Hello,

I need to create a graph similar to the picture attached. I have tried for several hours to do so with no luck. I need to create this in a Visual Studio. I can lay the data out any way necessary.

This seems like it should be simple so I am hoping I am just missing something obvious.

This is a somewhat urgent need so any elp is really appreciated.

Thanks,
John S.
Stef
Telerik team
 answered on 10 Jun 2013
1 answer
111 views
Hi,
I am using Report Viewer and Export option to PDF only.

what size i should set for Report Viewer to make a single page from Report into single page in PDF.

I want to have a page from Report in a page in PDF.

Help me to resolve this.

Thanks in advance.


Regards,
AGMRAJA
Ivan Hristov
Telerik team
 answered on 10 Jun 2013
1 answer
2.2K+ views

Whats wrong with this expression, logically i can print any default variable if a field comes as Null. 
= IsNull(Fields.ROE_wo_Reserves, Fields.Flat_Line_Rent) 

I am getting blank value as output everytime. 
Squall
Top achievements
Rank 1
 answered on 10 Jun 2013
1 answer
314 views
Hi,

When we tried to create a grouped bar chart against two different region (WEST, EAST) across defined months (01-Jan to 01-Jun), Grouped Bar chart is rendered correctly including X axis labels center aligned - Please refer the attached image - All_Data_Bar.png.

But we encountered the X axis label alignment problem (it's not in center against the bar) only if some of the months data is not available for one particular region (EAST) - Please refer the attached image - Grouped_Bar_Label_Center_Issue.png . Our customer is expecting that X axis label against the bar should be center aligned always.

Sometimes based on the data, we are getting the empty space between the bars against the group.- Please refer the attached image- Grouped_Bar_Space_Issue.png

Please advise how to resolve this issue? If you can provide code sample to acheive the desired result would be grateful.

Thanks
Sankar
IvanY
Telerik team
 answered on 07 Jun 2013
8 answers
711 views
I've been searching around for a way to change the 'Value' of a textbox during the ItemDataBound event, but I'm not seeing any examples.  I am binding to a SQLDataAdapter which calls a stored procedure to load the textboxes, so much of the data is stored in 'bit' column types.  What I need to do is simply change things like bit values '1' or '0' to 'Enabled' and 'Disabled' when the report is generated.

My first approach was to access the needed Textboxes in the ItemDataBound event and change their 'Text' or 'Value' field based on the appropriate row value.  But, these properties don't exist. 

Thanks.
Stef
Telerik team
 answered on 07 Jun 2013
7 answers
484 views
Hi,

We am using Telerik Reporting Q3 2011 on .Net Framework 4.0.

We found that the reportviewer cannot be released from memory even the form have been closed. 
By using the .Net Memory Profiler, we know that there is a event handler for "ToolStripTextBox" in reportviewer control which does not been removed after the form closed. So, "Disposed instances with direct EventHandler roots" problem occurred.

After testing, we found that only if we set the "ToolBarVisible" property to "False" in ReportViewer control, the memory can be released successfully.

So, any advise?

Thanks!

Emily
IvanY
Telerik team
 answered on 07 Jun 2013
5 answers
165 views
Hi
When i view report by binding it in page-load event its tollbar  style  is messed up. but if i add a button and bind report on its click event it is ok. What i am missing plz help me.
See attached pic to see how report looks like






IvanY
Telerik team
 answered on 07 Jun 2013
6 answers
783 views
I group records in my report. In group's footer section, i display a single value(which is actually same for the same group) onto my textbox from each and every single group in group footer section of the group. Then i need  to get all values of the textboxes in the groups footer section . How can i get them programmatically? I know how to get an item however, when an item(here textbox) being diplayed accoring to the number of the groups resides in final report, i don't know how i can get all the values?

Such as:

Telerik.Reporting.

TextBox txt = (ReportViewer.Report as MyRaport).Items.Find("textBox13", true)[0] as Telerik.Reporting.TextBox;

 

 

txt.Visible = false;

Could someone pls help me?

Thanks in advance...
Stef
Telerik team
 answered on 07 Jun 2013
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?