Telerik Forums
Reporting Forum
2 answers
383 views
i have been struggling, googling and searching my problem to no avail.

i am using reporting v5.3.11.1116  for exporting a chart. The axis are dates. I have played around with autoscale and setting step and label step, min value, and max value.

However, it seem to get the same result: The line is constructed and scaled properly, but the x-axis labels are always spaced evenly apart even when the time between points is varied.  Please see my attachment.

You will notice that one major tick is 2 months, but the next is 12 days. It conitnues like that.

Here are some of my current settings that wil not work.

            chart1.PlotArea.XAxis.MinValue = dataSeriesDisplayChartViewModel.DataSeriesDisplay.SelectedStartDate.AddDays(-1).ToOADate();
            chart1.PlotArea.XAxis.MaxValue = dataSeriesDisplayChartViewModel.DataSeriesDisplay.SelectedEndDate.AddDays(1).ToOADate();
            chart1.PlotArea.XAxis.Step = (chart1.PlotArea.XAxis.MaxValue - chart1.PlotArea.XAxis.MinValue)/10;

           this.chart1.PlotArea.XAxis.Appearance.LabelAppearance.Position.AlignedPosition = Telerik.Reporting.Charting.Styles.AlignedPositions.Top;
            this.chart1.PlotArea.XAxis.Appearance.LabelAppearance.RotationAngle = 45F;
            this.chart1.PlotArea.XAxis.Appearance.MajorGridLines.Color = System.Drawing.Color.Gainsboro;
            this.chart1.PlotArea.XAxis.Appearance.MajorGridLines.EndCap = System.Drawing.Drawing2D.LineCap.Flat;
            this.chart1.PlotArea.XAxis.Appearance.MajorGridLines.PenStyle = System.Drawing.Drawing2D.DashStyle.Solid;
            this.chart1.PlotArea.XAxis.Appearance.MajorTick.Color = System.Drawing.Color.Black;
            this.chart1.PlotArea.XAxis.Appearance.TextAppearance.TextProperties.Color = System.Drawing.Color.Black;
            this.chart1.PlotArea.XAxis.Appearance.ValueFormat = Telerik.Reporting.Charting.Styles.ChartValueFormat.ShortDate;
            this.chart1.PlotArea.XAxis.AutoScale = false;
            this.chart1.PlotArea.XAxis.AxisLabel.Appearance.Visible = true;
            this.chart1.PlotArea.XAxis.AxisLabel.TextBlock.Appearance.TextProperties.Color = System.Drawing.Color.Black;
            this.chart1.PlotArea.XAxis.AxisLabel.TextBlock.Appearance.TextProperties.Font = new System.Drawing.Font("Verdana", 9.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
            this.chart1.PlotArea.XAxis.AxisLabel.TextBlock.Text = "Observation Date";
            this.chart1.PlotArea.XAxis.AxisLabel.Visible = true;
            this.chart1.PlotArea.XAxis.DataLabelsColumn = "ObservationDateOADate";
            this.chart1.PlotArea.XAxis.IsZeroBased = false;


how do i get the x axis labels to display evenly spaced out values. It is okay if the labels do not match up with the points. For example, a data point on 1/15/12 could be by the actual label of 1/12/12.  we are printing out a separate report for the raw values in a different report.
Robert
Top achievements
Rank 1
 answered on 09 Jan 2012
1 answer
120 views
do the minor gridlines or tick marks appear on the X axis? If so, how?

i have this code, but still nothing appears, only the major lines.

my xaxis is a date value

            
chart1.PlotArea.XAxis.Appearance.MinorGridLines.Color =
Color.Black;<BR>           
chart1.PlotArea.XAxis.Appearance.MinorGridLines.EndCap =
LineCap.Flat;<BR>           
chart1.PlotArea.XAxis.Appearance.MinorGridLines.PenStyle =
DashStyle.Solid;<BR>           
chart1.PlotArea.XAxis.Appearance.MinorGridLines.Visible =
true;<BR>           
chart1.PlotArea.XAxis.Appearance.MinorTick.Visible =
true;<BR>           
chart1.PlotArea.XAxis.Appearance.MinorTick.Color = Color.Black;
Elian
Telerik team
 answered on 09 Jan 2012
1 answer
476 views
Hello,

I want to set a textbox with the next formula
[= "Date of " + Parameters.CALCDATE.Value]

For CALCDATE = '04/11/2011' The result is:

Date of 04/11/2011 00:00:00

The desired result is

Date of 04/11/2011

Format string is set to {0:d} but it does not work properly.
Instead I tried with

[="Date of" + Format({0:d}, Parameters.CALCDATE.Value)]

And it does not work either (it throws an error).

How can I set the format to this date?

Thank you very much.

Sergio.
Steve
Telerik team
 answered on 09 Jan 2012
1 answer
188 views
In a Telerik report table, I have a row containing a parent group (Classification) and a second row containing a child group (Detail).  Each classification can contain mutiple detail rows.  I am attempting to set this up as a drill down, with the detail rows hidden until toggled from the Classification.  To do this, I have tried the following:

In the first column cell of the Classification row, I am setting a "Toggle Visibility" action, and setting the Detail group as the toggle target.  In the group properties of the Detail group, I have set Visible = False (otherwise the rows are always displayed on the report).  When I run the report, only the Classificaiton rows are displayed in the table, with a toggle button in the first cell, as I intended.  However, when I click any of the toggle buttons, I get the following error:

An error has occurred while processing Table 'table1':
Index was outside the bounds of the array.

If I shut off the Toggle Visibility action, all rows are displayed in the report, and the error does not occur.  Any idea why the toggle feature would be encountering this error?
Hadib Ahmabi
Top achievements
Rank 1
 answered on 09 Jan 2012
1 answer
98 views
I wondering the best way to hide details of the reports based on the count.
My query has select top(1000), so only the top 1000 items are returned.  If I get 1000, I display a message saying please refine your parameters.
How should I set the visibility to hide the details and the groups.  I tried to set the binding of visibility to the expression
IIF( count(fields.field1) < 1000, true, false) , but that's not going to get a total count of the items.  What's a good way to do this?  Is there a total result set count?
Hadib Ahmabi
Top achievements
Rank 1
 answered on 09 Jan 2012
3 answers
194 views

I've a problem with Report Viewer...
In a first time it's all ok...
but after a while when loads the page, it starts to blink (i can't use the report parameters)...
If I press ESC the report parameters are not available but if I refresh the page data are available but the part of parameters continuos to blink...
The report don't works as it should...
What's happened?

Is possible thinking that a process locks the browser?
Can you help me?

Best wishes
Luca Martini

Lasly
Top achievements
Rank 1
 answered on 09 Jan 2012
1 answer
154 views
Hi Guys,
    I have made those reports have been shown by using the Silverlight ReportViewer on client-side.
    Furthermore,Those reports's parameters have been passed from the client-side silverlight to the server-side telerik reporting  reports. 
    
   Those reports have worked fine when those reports's parameters have beed selected all in first time.
   But,The report will occur blank data on the first page of the whole report when  I have selected some parameter in second time.
   
   Please see the code below
   *.xaml
      <telerik:ReportViewer x:Name="MyReportViewer" ReportServiceUri="../ReportService.svc"/>
   
   *.xaml.cs
       this.MyReportViewer.Report = null;
       this.MyReportViewer.Report = "ReportLibrary.ReportTest,ReportLibrary";
       this.MyReportViewer.RenderBegin += new RenderBeginEventHandler(ReportViewer_RenderBegin);
       ....
       ....// passed the report parameters
       args.ParameterValues["Plant"] = plants;
       args.ParameterValues["Areas"] = areas;
       args.ParameterValues["Units"] = units;
       args.ParameterValues["Items"] = items;

   ReportTest.cs [Telerik.Reporting.Report]
      private void ReportTest_ItemDataBinding(object sender, EventArgs e)
      {
          .....//got the report parameters
          .....//generated and executed the mdx query , returned cellset
          .....//Telerik Table Bind the cellset data
           this.tblTest.DataSource = cubeTest;
           //----------------------Fields Binding------------------------------------
          this.txtFChgOn.Value = "=IsNull(FormatDate(Fields.Time),' ')";
          this.txtFArea.Value = "=Fields.Area";
          this.txtFUnit.Value = "=Fields.Unit";
          this.txtFTagName.Value = "=Fields.TagName";
          this.txtFTagDesc.Value = "=Fields.TagComment"; 
      }


   I think,Does the report has cached report data in first time?
   How can I handle this situatio ?
   In case of the cached data , How to solve it?
  
   I am in urgent need of yours help.
  Thanks.
Peter
Telerik team
 answered on 09 Jan 2012
0 answers
111 views
It's simple enough to set a design-time connection string with the Report Wizard. But I'm having a very difficult time trying to set a connection string that will work once the  Winforms App is deployedl.  I have tried using Path.GetDirectoryName Application.ExecutablePath etc. but nothing wants to work. I know there's some simple and probably elegant solution to this, but I'm stuck and must reach out for help.  Any ideas on the best way to do this? I'm using a SQLDataSource and it's connection string finds everything I try disagreeable.  Thanks in advance.
John
Top achievements
Rank 1
 asked on 07 Jan 2012
4 answers
291 views
Hello,

We're using Telerik Reporting Q2 2011 in a WPF C# application.  I'm creating a simple report with one group.  Can you please give suggestions regarding how to make a detail section textbox have bold font when there's only 1 row in the current group?

Thanks much!
Terry Webster
Top achievements
Rank 1
 answered on 06 Jan 2012
6 answers
436 views
Please could you let me know if there is a way to restrict the maximum bar width of a bar in the stacked bar chart? I have a variable number of items that need to be plotted, and if I only have one item on the x axis I would prefer the bar not to fill the width of the chart.

Thanks in anticipation, Carl
Rob
Top achievements
Rank 1
 answered on 05 Jan 2012
Top users last month
Miljana
Top achievements
Rank 2
Iron
Iron
Joel
Top achievements
Rank 3
Bronze
Bronze
Bronze
Cynthia
Top achievements
Rank 1
John
Top achievements
Rank 1
Iron
Mozart
Top achievements
Rank 1
Iron
Veteran
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?