Telerik Forums
Reporting Forum
1 answer
297 views
I have report viewer with a dark blue background and when the report loads, the default progress indicator with the white background does not look good (see attached). I can't seem to find any accessor for setting my own image in place of it. There are no style sheets in the reporting dir. Is this even possible?
Chavdar
Telerik team
 answered on 19 Oct 2011
1 answer
89 views
Hi,
we like to deliver the reports within our silverlight App.
Means: The User clicks the 'Reportbutton' and the report should be open in one of our application windows (UserControl).
Any idea if and how this is to be implemented?

thx.
Svetoslav
Telerik team
 answered on 19 Oct 2011
1 answer
64 views
I have constructed a collection of data series items. Each data series has multiple data points. 

I am binding all this to a bar chart. That data binding is working fine however for some reason beyond my comprehension the reporting engine has decided that all my bar chart items will be aligned to the left side of the chart. 

Currently the way my report is rendering is unacceptable. Is there a way to fix this (Please see attached screenshot)

Cheers !
Peter
Telerik team
 answered on 19 Oct 2011
7 answers
1.0K+ views
Hi

I need to save a reports parameters and their values. Passing the report to the report viewer control makes life alot easier as the control builds all the neccesary parameters.
Is there a way to get the event that the Preview button fires? i would think that this event will pass all parameters and values to the actual report for it to be rendered, and i can simply get the parameters and values from its event args.
If its not possible, is there another way that can be helpful for my scenario.  

thanks
Avesh
Squall
Top achievements
Rank 1
 answered on 19 Oct 2011
5 answers
691 views
Hello,
how can I have a particular formatting on last row? I need to hide the bottom border.... I've tried with =Count(Fields.Descr) == =RowLines() but seems RowLines is 1 based...
thanks
Peter
Telerik team
 answered on 19 Oct 2011
1 answer
190 views
i have two datasources in my report one for main report and another one for table, in data explorer only the main report datasource is showing. how would i find the data explorer for table data source?
Peter
Telerik team
 answered on 19 Oct 2011
1 answer
189 views
Hi there, I need to access the value of a subreports parameter inside the NeedDataSource event. How is this best accomplished?

I have tried the following but the value never changes:
private void chart1_NeedDataSource(object sender, EventArgs e)
{
    Telerik.Reporting.Processing.Chart procChart = (Telerik.Reporting.Processing.Chart)sender;
    Telerik.Reporting.Chart chart = (Telerik.Reporting.Chart)procChart.ItemDefinition;
 
    chart.ChartTitle.TextBlock.Text = chart.Report.ReportParameters["Branch"].Value.ToString();
}

When I have a Databind event for a textbox I can the following:
private void textBox3_ItemDataBinding(object sender, EventArgs e)
{
    Telerik.Reporting.Processing.TextBox procTB = (Telerik.Reporting.Processing.TextBox)sender;
    Telerik.Reporting.TextBox tb = (Telerik.Reporting.TextBox)procTB.ItemDefinition;
 
    tb.Value = "= Parameters.Branch.Value";
}
This works but how can I get the parameter's value into string object?

Regards,
Christian
Peter
Telerik team
 answered on 19 Oct 2011
3 answers
331 views

Hi All,

I have a multi-tenant database based on Microsoft SQL Azure to store my client info and I am using Telerik Report to for my Report modules.

Since I have to pull info from different database for different client, how do i dynamically configure my connection at web.config in order to know which database am i pulling from?

Please advise
Thanks You.

Eg.

<connectionStrings>

    <add name="ReportClassLib.Properties.Settings.ClientDB" connectionString="**;Initial Catalog=DB_1;User ID=**;Password=**"

            providerName="System.Data.SqlClient" />

</connectionStrings>

Client 1 is DB_1, Client 2 is DB_2,……

IvanDT
Telerik team
 answered on 19 Oct 2011
3 answers
131 views
I am using version 2011 Q2.
I am trying to get some HTML outputs to work in the WebForms viewer, and am using the RadEditor as the means by which to collect this information.
I have stripped down the input to the HTMLTextBox to those tags that are supported such as :
<p><span style="font-size: 24px;"><strong>EXECUTIVE SUMMARY</strong></span></p>
<p>Overall, the audit process was a success, if not the results.<br />
<br />
</p>
<p><span style="font-size: 22px;"><strong>The Good</strong></span></p>
<p>We had positive outcomes in the areas of...<br />
<br />
</p>
<p><span style="font-size: 22px;"><strong>The Bad</strong></span></p>
<p>We need to address the following things :</p>
<ul>
    <li>this thing which needs fixing </li>
    <li>this other thing which needs to be looked at - important </li>
    <li>other stuff too </li>
</ul>
<p>Following are the detail results of this audit.</p>

The issue is that the <ul> items do not show the bullet points in the HTML view.
The items display correctly when exported to PDF.
Can you advise on a course of action?
Thanks,
Steele.

IvanDT
Telerik team
 answered on 18 Oct 2011
1 answer
188 views
I am programmatically building my bar chart, but I have been unable to set the colors for the bar chart bars. Any suggestions or ideas? I am using Q2 2011 Telerik Reporting.


private void chart1_NeedDataSource(object sender, EventArgs e)
    {
        /*
            Need to just do two things in the designer        
            1.) AutoLayout = True
            2.) Docking = Fill
         
        */
        DataTable dt = this.rptDt;

        this.chart1.DataSource = dt;
        chart1.Legend.Appearance.GroupNameFormat = "Qtr #VALUE";
        //return;

        //absolutely necessary these two lines of code:
        this.chart1.DataGroupColumn = "qtr";
        this.chart1.PlotArea.XAxis.DataLabelsColumn = "equipment";


        this.chart1.PlotArea.XAxis.AutoScale = true;
        this.chart1.Docking = DockingStyle.Fill;
        this.chart1.ChartTitle.TextBlock.Text = "Quarterly Equipment Failure";

        this.chart1.PlotArea.YAxis.Appearance.MajorGridLines.Visible = false;
        this.chart1.PlotArea.YAxis.Appearance.MinorGridLines.Visible = false;

        this.chart1.PlotArea.XAxis.Appearance.MajorGridLines.Visible = false;
        this.chart1.PlotArea.XAxis.Appearance.MinorGridLines.Visible = false;

        this.chart1.ClearSkin();
        this.chart1.Skin = string.Empty;
        this.chart1.SeriesPalette = string.Empty;

        this.chart1.Style.BackgroundColor = System.Drawing.Color.WhiteSmoke;
        this.chart1.PlotArea.Appearance.FillStyle.MainColor = Color.White;
        this.chart1.PlotArea.Appearance.FillStyle.FillType = Telerik.Reporting.Charting.Styles.FillType.Solid;
        //this.chart1.PlotArea.XAxis.Appearance.LabelAppearance.FillStyle.MainColor = System.Drawing.Color.Black;
        this.chart1.PlotArea.XAxis.Appearance.TextAppearance.TextProperties.Color = System.Drawing.Color.Black;
        this.chart1.PlotArea.YAxis.Appearance.TextAppearance.TextProperties.Color = System.Drawing.Color.Black;

        //chart1.PlotArea.XAxis.Appearance.LabelAppearance.RotationAngle = 180;

        chart1.DefaultType = ChartSeriesType.Bar;
        chart1.SeriesOrientation = ChartSeriesOrientation.Horizontal;
        //chart1.SeriesOrientation = ChartSeriesOrientation.Vertical;

        ChartSeries cs = new ChartSeries();
        ChartSeriesItem csi;// = new ChartSeriesItem();       

        //Make 4 Series that are the Quarters (1,2,3,4)
        for (int i = 1; i < 5; i++)
        {
            cs = new ChartSeries("Qtr " + i.ToString(), ChartSeriesType.Bar);
            //add the new series to the chart:
            switch (i)
            {
                case 1:
                    cs.Appearance.LineSeriesAppearance.Color = System.Drawing.Color.Blue;
                    cs.Appearance.FillStyle.MainColor = System.Drawing.Color.Blue;                    
                    break;
                case 2:
                    cs.Appearance.LineSeriesAppearance.Color = System.Drawing.Color.Red;
                    cs.Appearance.FillStyle.MainColor = System.Drawing.Color.Red;
                    
                    break;
                case 3:
                    cs.Appearance.LineSeriesAppearance.Color = System.Drawing.Color.Yellow;
                    cs.Appearance.FillStyle.MainColor = System.Drawing.Color.Yellow;                    
                    break;
                case 4:
                    cs.Appearance.LineSeriesAppearance.Color = System.Drawing.Color.Green;
                    cs.Appearance.FillStyle.MainColor = System.Drawing.Color.Green;
                    break;
            }

            //make the bars solid instead of gradient
            cs.Appearance.FillStyle.FillType = Telerik.Reporting.Charting.Styles.FillType.Solid;
            cs.Appearance.LegendDisplayMode = ChartSeriesLegendDisplayMode.SeriesName;

            chart1.Series.Add(cs);
        }



        //now add each equipment fail count to the respective quarter:        
        //build the bars manually:
        foreach (DataRow r in dt.Rows)
        {
            //1.) Make a new series item for each new distinct Equipment item:
            csi = new ChartSeriesItem(Convert.ToDouble(r["failcount"]), r["failcount"].ToString());
            csi.Name = r["equipment"].ToString().Trim();

            csi.Appearance.FillStyle.MainColor = System.Drawing.Color.Purple;
            csi.Appearance.FillStyle.FillType = Telerik.Reporting.Charting.Styles.FillType.Solid;

            chart1.Series[Convert.ToInt32(r["qtr"]) - 1].AddItem(csi);
            
        }

        //show the years we used for the data:
        string msg = string.Empty;
        if (this.ReportParameters["YearsUsedInQuery"].Value.ToString().IndexOf("-") > 0)
            msg = "Years ";
        else
            msg = "Year ";

        this.chart1.PlotArea.YAxis.AxisLabel.TextBlock.Text = msg + this.ReportParameters["YearsUsedInQuery"].Value.ToString();
        this.chart1.PlotArea.YAxis.AxisLabel.TextBlock.Appearance.TextProperties.Color = System.Drawing.Color.Black;
        this.chart1.PlotArea.YAxis.AxisLabel.Visible = true;

        //this.chart1.DataSource = dt;
        ///*
        foreach (ChartSeries cs1 in chart1.Series)
        {
            switch (cs1.Index + 1)
            {
                case 1:                     
                    cs1.PlotArea.XAxis.Appearance.Color = System.Drawing.Color.Blue;
                    foreach (ChartSeriesItem ci in cs1.Items)
                    {
                        ci.Appearance.FillStyle.MainColor = System.Drawing.Color.Purple;
                        ci.Appearance.Border.Color = System.Drawing.Color.Purple;
                        ci.Appearance.Exploded = true;
                        ci.Appearance.FillStyle.FillType = Telerik.Reporting.Charting.Styles.FillType.Solid;
                    }
                    break;
                case 2:
                    cs1.PlotArea.XAxis.Appearance.Color = System.Drawing.Color.Red;
                    break;
                case 3:
                    cs1.PlotArea.XAxis.Appearance.Color = System.Drawing.Color.Yellow;
                    break;
                case 4:
                    cs1.PlotArea.XAxis.Appearance.Color = System.Drawing.Color.Green;
                    break;
            }
        }
         //* */
    }
IvanDT
Telerik team
 answered on 18 Oct 2011
Top users last month
Boardy
Top achievements
Rank 2
Veteran
Iron
Benjamin
Top achievements
Rank 3
Bronze
Iron
Veteran
ivory
Top achievements
Rank 1
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
ClausDC
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?