Telerik Forums
Reporting Forum
4 answers
362 views

Hi,

I have a custom resolver working with my html report viewer to display trdx's just fine. Some reports though are not trdx though so I will create these purely in code (in my resolver?) and pass the report to the viewer. I have tried the code below and it seems to work but I just need to confirm that I am doing it the correct way?

ie. is it correct to return a report object instance from the custom resolver?

public class MyResolver : IReportResolver
{
    public Telerik.Reporting.ReportSource Resolve(string report)
    {
        Report rpt = new Report();
 
        ObjectDataSource ods = new ObjectDataSource();
        ods.DataSource = GetSomeData();
        rpt.DataSource = ods;
     
    /*
    ...code to set up report items...
    */
             
        return rpt;
}
 }

 

 

Katia
Telerik team
 answered on 07 Sep 2016
1 answer
330 views

Hi,

We are evaluating telerik reports.

The below code snippet is defined in the Report Controller. Report works fine. But when a report is generated, the number of open connection of the telerikSession (used only for cache) is high and they do not get closed. I tried with one user, running one report and the number of openconnections is 30. Can you help me sort out this issue?

static ReportServiceConfiguration preservedConfiguration;
static IReportServiceConfiguration PreservedConfiguration
{
get
{
if (null == preservedConfiguration)
{
preservedConfiguration = new ReportServiceConfiguration
{
HostAppId = "ABC",
Storage = new MsSqlServerStorage(ConfigurationManager.ConnectionStrings["TelerikSession"].ConnectionString),
//Storage = new FileStorage(),
ReportResolver = new OrgnResolver(),
ReportSharingTimeout = 0,
// ClientSessionTimeout = 15,
};
}
return preservedConfiguration;
}
}

Thanks

Stef
Telerik team
 answered on 07 Sep 2016
1 answer
190 views

If I have the Reporting WebAPI setup so that it's working, ie http://localhost:56200/api/v1/report/ is returning:

[{"name":"PDF","localizedName":"Acrobat (PDF) file"},{"name":"CSV","localizedName":"CSV (comma delimited)"},{"name":"XLS","localizedName":"Excel 97-2003"},{"name":"RTF","localizedName":"Rich Text Format"},{"name":"IMAGE","localizedName":"TIFF file"},{"name":"MHTML","localizedName":"Web Archive"},{"name":"XPS","localizedName":"XPS Document"}]

What would cause a 404 when attempting to retrieve a template? ie:

http://localhost:56200/api/v1/report/resources/templates/telerikReportViewerTemplate-html

Stef
Telerik team
 answered on 07 Sep 2016
1 answer
398 views
Hey my headers sometimes are not attaching to a csv export at work. I am doing nothing differently. Example of scenario today. Logged in exported to csv and worked no problem. Reset the application repeated exact same steps with no difference and no headers. I've attached screenshots of the problem. Any pointers on how to fix this would be greatly appreciated.
Katia
Telerik team
 answered on 05 Sep 2016
12 answers
1.0K+ views

  We are using Telerik Reporting to generate our report, we are facing following problems.

Stef
Telerik team
 answered on 02 Sep 2016
5 answers
233 views
In crosstab when I set the angle to 270, the text alignment is ignored and is always right aligned. Please see the attached screenshots. Is there a way for the report to actually align as set on design?
Katia
Telerik team
 answered on 02 Sep 2016
7 answers
296 views

Can anyone explain the paging that is happening in this report?

Ive set KeepTogether = false everywhere I can think of. Also Group Keep Together is false.

But it is still throwing pages as if KeepTogether was true in some places.

Katia
Telerik team
 answered on 02 Sep 2016
1 answer
243 views

Hello,

 

I am trying to create a Pie chart in code, and it is not looking like a pie, i feel like an just missing a setting at the points, but all resources I have read/reviewed have not helped be finish it. Thank for any help!

01.ObjectDataSource src = new ObjectDataSource(curScope,"GetData");
02. 
03.Telerik.Reporting.Graph test = new Graph()
04.{
05.    NoDataMessage = "Yes, we have no data",
06.    Location = new PointU(Unit.Inch(0), Unit.Inch(0)),
07.    Size = new SizeU(Unit.Inch(8.0D), Unit.Inch(3.0D)),
08.    StyleName = "Normal.TableGroup",
09.    DataSource = src,
10.    Name = "graph"+colIndex.ToString()               
11.};
12. 
13.test.Titles.Add(new GraphTitle() { Text = "% of" + ReportTitle });
14. 
15.BarSeries pie = new BarSeries();
16.pie.Name = "pie" + colIndex.ToString();
17.var pallet = new ColorPalette();
18.pallet.AddColors(Color.Red, Color.Blue, Color.Green, Color.Yellow, Color.Orange);
19.pie.ColorPalette = pallet;
20.test.ColorPalette = pallet;
21. 
22.GraphGroup category = new GraphGroup()
23.{
24.    Name = "cat1"
25.};
26.category.Groupings.Add("=Fields.IngredientName");
27.pie.CategoryGroup = category;
28.test.CategoryGroups.Add(category);
29. 
30.GraphGroup series = new GraphGroup()
31.{
32.    Name = "series1"
33.};
34.series.Groupings.Add("=Fields.PercentOfTotal");
35.//series.Sortings.Add("=Sum(Fields.PercentOfTotal)", SortDirection.Desc);
36.//series.Sortings.Add("=Fields.IngredientName", SortDirection.Asc);
37.//series.Filters.Add("=Sum(Fields.PercentOfTotal)", FilterOperator.TopN, "20");
38.pie.SeriesGroup = series;
39.test.SeriesGroups.Add(series);
40. 
41.PolarCoordinateSystem polar = new PolarCoordinateSystem();
42. 
43.var radCat = new Telerik.Reporting.GraphAxis()
44.{
45.    Name = "radialAx1",
46.    Scale = new CategoryScale()
47.    {
48.        //SpacingSlotCount = 0,
49.        PositionMode = AxisPositionMode.OnTicks                   
50.    }
51.};
52. 
53.var angNum = new Telerik.Reporting.GraphAxis()
54.{
55.    Name = "angularAx1",
56.    Scale = new NumericalScale()
57.    {
58.        //SpacingSlotCount = 1
59.    }
60.};
61. 
62.polar.Name = "polarScale";
63.polar.RadialAxis = radCat;
64.polar.RadialAxis.Style.Visible = false;
65. 
66.polar.AngularAxis = angNum;
67.polar.AngularAxis.Style.Visible = false;
68. 
69.test.CoordinateSystems.Add(polar);
70.pie.CoordinateSystem = polar;
71.                      
72.pie.X = "=IsNull(Sum(Fields.PercentOfTotal), 0)";
73.pie.LegendItem.Value = "=Fields.IngredientName";
74.pie.ArrangeMode = GraphSeriesArrangeMode.Stacked100;
75.//pie.DataPointLabel = "Sum(Fields.PercentOfTotal)/1000";
76.//pie.DataPointLabelFormat = "{0:C0}K";

Stef
Telerik team
 answered on 01 Sep 2016
1 answer
267 views
I want to export my report in XPS format. I am using Telerik Reporting. PDF, and XLS format are working perfectly but . I had also added Xpsrendering.dll but .
can you help me in this matter?
Stef
Telerik team
 answered on 01 Sep 2016
1 answer
73 views

I have an existing Telerik report - designed in Visual Studio. It's been in production for several months. When I try to change the object data source on it now, it throws an error (can't load type xxx from assembly xxx). There's absolutely nothing wrong with my assemblies, this project compiles and runs fine and has been in production for several months as I said.  Any idea what's causing this?  I cannot contact support because the license has expired.

 

Katia
Telerik team
 answered on 01 Sep 2016
Top users last month
Chester
Top achievements
Rank 1
Iron
Simon
Top achievements
Rank 1
Iron
Douglas
Top achievements
Rank 2
Iron
Iron
SUNIL
Top achievements
Rank 3
Iron
Iron
Iron
Marco
Top achievements
Rank 3
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?