Telerik Forums
Reporting Forum
0 answers
173 views
I'm getting the following erro when trying to use a report parameter as datatype datetime.

'An error occurred while processing the table 'ChangeRequestTable' Table':
Arithmetic overflow error converting expression to data type smalldatetime.

If I display the value of the ReportParamter I get a value like
13/03/2011 13:05:48

If I try to use a value in this format in my SqlDataSource I get the same Arithmetic Overflow error.
The SqlDataSource works fine if the value is in the following format:
2011-03-13 00:00:00

Can you tell me how I can get the ReportParamter to return the date in a format that the SqlDatasource will accept?

I've tried numerous things...
I've tried wrapping the paramter in the SQLDatasource query...i.e.
    CONVERT(VARCHAR(19),@StartDate,120)
I've tried converting the paramtyer expression...
    =CDATE(Paramters.ReportPeriodStartDate.Value).ToShortDateString
I've tried changing the databasedata type from smalldatetime to datetime...
I'm out of ideas...

I've opened a support ticket but no response yet :-(

I'm sure this shouldn't be a difficult thing.
Its always the small unexpected things that puts a spanner in the works :-( 

Many Thanks in advance, Des
des white
Top achievements
Rank 1
 asked on 15 Mar 2011
2 answers
107 views
I have created a report and it runs just fine if I manually put the parameter values in the query builder. I am using a SQL Data source that looks like this:
SELECT     REJECT_REPORT.VENDOR, COUNT(DISTINCT REJECT_REPORT.REJECT_ID) AS QTY_RRs, RR_CATEGORY.CATEGORY, @startDate AS STARTDATE,
                      @endDate AS ENDDATE
FROM         REJECT_REPORT LEFT OUTER JOIN
                      RR_CATEGORY ON REJECT_REPORT.CATEGORY = RR_CATEGORY.CATEGORY_ID
WHERE     (REJECT_REPORT.OCCURENCE_DATE BETWEEN @startDate AND @endDate)
GROUP BY REJECT_REPORT.VENDOR, RR_CATEGORY.CATEGORY, REJECT_REPORT.CATEGORY
 
I have tried all sorts of things trying to input the parameter. Including:
ReportViewer1.Report.ReportParameters("@endDate").Value =
frmDateInput.dtpEnd.Value.ToShortDateString

Dim report As New CategoryReport

        report.ReportParameters.Add("@startDate", Telerik.Reporting.ReportParameterType.DateTime, "9/1/2010")
        report.ReportParameters.Add("@endDate", Telerik.Reporting.ReportParameterType.DateTime, "9/30/2010")

        ReportViewer1.Report = report
Dim report As New CategoryReport

        report.ReportParameters.Add("@startDate", Telerik.Reporting.ReportParameterType.DateTime, "9/1/2010")
        report.ReportParameters.Add("@endDate", Telerik.Reporting.ReportParameterType.DateTime, "9/30/2010")

        ReportViewer1.Report = report
Dim report As New CategoryReport

        report.ReportParameters.Add("@startDate", Telerik.Reporting.ReportParameterType.DateTime, "9/1/2010")
        report.ReportParameters.Add("@endDate", Telerik.Reporting.ReportParameterType.DateTime, "9/30/2010")

        ReportViewer1.Rep

Dim report As New CategoryReport
 
        report.ReportParameters.Add("@startDate", Telerik.Reporting.ReportParameterType.DateTime, "9/1/2010")
        report.ReportParameters.Add("@endDate", Telerik.Reporting.ReportParameterType.DateTime, "9/30/2010")
 
        ReportViewer1.Report = report

Am I doing this right?

I just want to send 2 date values to my report.

Thanks,
Charles Hawk
des white
Top achievements
Rank 1
 answered on 15 Mar 2011
2 answers
398 views
Hi,

   How can I get the group record rows count and display in the footer of group? I tried =Rowcount  as expression in a textbox but didn't worked.

   Thanks,
Jeremy Greenberg
Top achievements
Rank 1
 answered on 15 Mar 2011
0 answers
172 views
Telerik report not showing correctly when it is printed in pdf format

I have an ASP page with a report viewer for showing a telerik report.The report viewer's width property  is given 100%, height property  is given 100% and Zoom mode property is given as FullPage .
The telerik report is given with legal paper kind  (8.5  x 14 inch) . The telerik report's  width  property is set to 8.5 inch.
When the page is executed the report is showing correctly, but when it given for printing in pdf format with preference given as legal size and portrait, the pdf print format output shows only part of the report with vertical and horizontal scroll bars of report viewer.
I am attaching the pdf print output of the report.
Mike Treat
Top achievements
Rank 1
 asked on 15 Mar 2011
8 answers
162 views
I have a page called Report.aspx that has the Telerik ReportViewer control on it.  During the OnLoad event of Report.aspx I would like to set the report that will be viewed.  How do I do this?
Robert Dennyson
Top achievements
Rank 2
 answered on 14 Mar 2011
1 answer
116 views
Hello,

    We are evaluating telerik report control to see whether it can support our requirement.  so far we have these two questions:
1. Can we develop a custom chart control and use it in the report, the reason why I ask is, one of our chart is quite unique, the standard chart control can't support it. 
2 Can we extend the export feature of report, I mean, we need to export the report to native word document, I know telerik can export to rtf format , but it is not good enough, as we need to generate image numbers, control the font used in word, and furthermore, once it has been export to word(doc), customer can easily to change it. if it is possible we would like to provide a custom export feature, but so far we don't know how to do it. 

Could you please let me know whether it is possible? if it is possible how to do it , where is the technical materials(document).

Thanks and regards

Johnny

Steve
Telerik team
 answered on 14 Mar 2011
3 answers
169 views
I have a report that has dynamically created html text based on the data. I would like to have a footnote associated with one of those HtmlTextBox controls to appear at the bottom of the page on which the section occurs. I looked at Docking as a possible solution but that seems to dock with a section and not a page.

Is there a way to:
 1) Have a control (e.g., HtmlTextBox) appear at the bottom of the page on which another control appears with the page # not being known in advance? -- My ideal solution.

 2) A way to change the page footer on a specific page to include the footer text.-- A fallback solution
      (I have been able to add a control to the footer that only displays on the specified page number. However, on all of the other pages it has the height needed to include the footer which makes it to tall. According to your help file "the height of the PageHeader and PageFooter section that is set at design-time is always preserved..." so I seem to have no choice with this.)

Thanks,

Matthew

Peter
Telerik team
 answered on 14 Mar 2011
1 answer
405 views
When trying to have a report with a column count, I'm unable to change the widths of the columns.  For example, I have a report that needs to be split into 3 columns.  This report needs to have all 3 left justified right next to each other.  The columns must have a width of 2.5in.  I've set the column width to 2.5in with 3 columns, but it never goes under ~3.5in.  How can this be resolved?  It's causing too much white space between the columns.
Peter
Telerik team
 answered on 11 Mar 2011
1 answer
241 views
The best way to describe the kind of report I must produce is to imagine having to create a report that displays a blog entry.

The report header would need to show the author, date and most importantly the body of the blog entry. For this reason, I need the report header to automatically grow (the header, not just the field Furthermore, if it’s large enough, the reporting system needs to page it.

Secondly, I need to display all the comments in the item detail. Comments can be rather long themselves, so they produce the same questions as above. 

Is this possible with the reporting system?

Peter
Telerik team
 answered on 10 Mar 2011
1 answer
154 views
I have an invoicing processing that loops through and generates multiple (200-300) reports.  My report is a main report that contains 5 subreports.  My main report has 3 different background images, one on the Report Header, one on an unbound group header and then one for the Report (which displays for every page but the report header and the 1st group header).  Each image is a png file that fills a 8x11 page.

Currently I create a new report object for each invoice.  I have a shared ReportProcessor that I use to get each report as a pdf file in a memory stream and then store the document in the database.  Then I either email or fax the memory stream OR print the original report object.  I ran into problems last month where after 10-20 report I got an Argument exception and it mentioned the BackgroundImage property.  Unfortunately I cannot remember the exact error or reproduce it without printing all the reports.

Any ideas or suggestions?  Can I share a report processor like that?  Should I recreate the report each time?  I will try and re-generate the error by pausing the print queue and letting the code go through the steps.

Example code:
Dim rp as new ReportProcessor, r as InvoiceReport, ms as MemoryStream
for each itm in list( of items)
     r=New InvoiceReport
     rp.RenderReport("PDF", r, Nothing)
     'database save code
    Select itm.SendFormat
       Case email,fax
            'do email/fax processing with memory stresm
       Case paper
            rp.PrintReport(r,settings)
    End Select
    r.dispose
    ms.dispose
   
Steve
Telerik team
 answered on 10 Mar 2011
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?