DateTime picker and the ReportViewer

Hi,

I am running SQL Server 05 (SP 1 CTP) and Visual Studio 05.

Is the reportViewer used for the Asp.net webforms supposed to have a working date time picker control I know that this was an issue on the beta 2 but I am still expericiencing the same problem.  The date report parameters work fine on the preview but when displayed on the ReportViewer in a webform  they don't work.

I am running version 8.0.0.0 of the  Microsoft.ReportViewer.WebForms

Thanks, Mauricio




Answer this question

DateTime picker and the ReportViewer

  • stg1

    visual studio was the problem for me. when I ran my report outside of visual studio, it worked great. So I can just ignore that error because it won't show up in production. I like those kinds of errors.


  • Rodrigo Wolburg

    the control does show. But when you click on the calendar icon the popup calendar does not show up and the page simply reloads.

  • fuzzfoot

    Are you explictly setting relative or absolute positioning on any of the controls on your page If so, does using the default cause the calendar to show up
  • Omar Hector 123

    I'm getting a similar problem. The following message is displayed to the client when the calendar icon is click and a date is selected.

    Microsoft JScript runtime error: 'resultfield.id' is null or not an object

    After investigating the problem further using the javascript debuuger I found that the problem was being caused in the ClickDay function, the following line being the culprit:

    var eltValidator=win.parent.document.getElementById(ifrm.resultfield.id+g_strDatePickerRangeValidatorID);

    I've look at the supplied Microsoft ASP.NET 2.0 application supplied with SQL Server
    Express 2005 Reporting Services and there version works fine without any errors.

    http://localhost/ReportServer$SQLExpress/Pages/ReportViewer.aspx

    If anybody could shed anymore light on the problem or a suggestion for a workaround, that would be great!!!.

  • Chango V.

    Can you be more specific about how it doesn't work Do you get an error message Does the calendar not show up at all
  • David McComb

    Now I am getting the javascript error when selecting a date on a page with no layout and only the ReportViewer control. The confusing thing is that it doesn't happen on every run which lead to a misdiagnosis of the cause.

    The error:

    resultfield.id is null or not an object

    occurs in ClickDay on the line:

    var eltValidator=win.parent.document.getElementById(ifrm.resultfield.id+g_strDatePickerRangeValidatorID);

    I tried running the application outside of the Visual Studio environment and it works fine (so far).

    Therefore, it may be that the error only occurs when the application is run under visual studio.


  • Ed Psyk

     

    I figured out the cause on my case. The evil Reporviewer does not generate the apropiate javascript code when inside a master page.

    I removed the master page code from my aspx page and sure enough the date controls work!!!

    I hope  this helps,



  • TTE

    I am also having this problem, anyone have a solution, or does the reportviewer control just flat out not work

  • Michael Pollard

    We are also having this problem. We're not using master pages incidentally. Anyone have an update on this
  • JosRyan

    Leung, I get the exact same error. I am at a loss here. Is anyone else experiencing the same problem

  • Jasimons

    I have similar problems...... a javascript error (saying "object required") when I click on the calendar icon next to the textbox and then the page just reloads itself.
  • furtivefelon

    This problem does not occur because you are using a master page but because the javascript relies on the fact that the control is in a fixed position on the page. Any containing elements, divs etc. that use relative positioning cause the javascript for this control to fail when it tries to position the div used to display the calendar. Because of this and other reasons, I have found that it is very hard to place the reportviewer control into existing layouts (ie. a master page) and have since abandoned this approach.


  • rumen101010

    I too am getting this annoying error. Has anyone found a workaround. Please help.


  • DateTime picker and the ReportViewer