ReportViewer Control Data not showing RRS feed

  • Question

  • Hi,


    Iam running my existing reports from application. Iam using "ReportViewer" Control to show the report. below code Iam using to show the report on Viewer control.


    When iam Showing report body is not showing[Blank showing] any data. But Tool bar and pages count is showing . If i change the parameters also pages count is changing. if i export the data into PDF or any other format data is showing in that format.


    Why iam not able to see the data on my report viewr control.


    ReportParameter[] parm = new ReportParameter[5];

    parm[0] = new ReportParameter("F_code", SelectedfamiliesList,false);

    parm[1] = new ReportParameter("C_code", SelectedCropsList,false);

    parm[2] = new ReportParameter("P_code", SelectedPlantsList, false);

    parm[3] = new ReportParameter("status_code", SelectedInvstatusList, false);

    parm[4] = new ReportParameter("Period", period, false);

    ReportViewer1.ProcessingMode = Microsoft.Reporting.WebForms.ProcessingMode.Remote;

    ReportViewer1.ServerReport.ReportServerUrl = new System.Uri("http://Test/ReportServer");

    ReportViewer1.ServerReport.ReportPath = "/TestReports/Test";




    If any body knows the solution please help me....




    Tuesday, September 18, 2007 4:49 PM


  • Hi Guys,

    Actually problem is with the Viewer control. Just i removed the viewer control, aspx page and again i have taken fresh page and control. Now those are working fine.

    This solved my problem........ Thanks to all.

    Monday, July 14, 2008 11:20 AM

All replies

  • Caveat: I don't use the web reportviewer version and am not a web developer. I am just thinking out loud here...


    It occurs to me that if the data is displaying in PDF etc (different renderer) but not in the default/standard view, it might be something about your report that is tripping up the default renderer whilst not generating any obvious errors.


    Can you run the report under debug control? If so the reportviewer sometimes generates meaningful diagnostics in the debug output window that otherwise go to the bitbucket.


    Thursday, September 20, 2007 12:15 AM
  • There are several possibilities.  One of thing, believe it or not, is your page's doctype.  So what is it?


    You may also have to set your ReportViewer control to an explicit (px) value rather than 90% or whatever...


    Other potential culprits: are you using any Ajax update panels in this page?  Is there a master page?




    • Proposed as answer by Ksheera Sagar Friday, May 25, 2012 4:38 PM
    Thursday, September 20, 2007 12:44 PM
  • Lisa,


    I am having the same problem that the other guy was having.  I have the control set to H and W of 100%.  The doctype is listed as...

    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "">


    I have set the H and W as low as 90%.  I tried Local and Remote.  I am running my app with master pages, but this form is opened without one.  I use Javascript to open the new form that only contains the ReportViewer control and some code to interpret the query string.


    Any ideas?




    Jim Evans, MCAD


    Sunday, December 2, 2007 3:59 AM
  • >> any ideas?




    Try changing your doctype to <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" >.


    Not saying you should do it permanently, just to see if that's what's causing the problem.  If it is, and there is a good chance it is, we can stop looking <sigh>.  If not, we'll proceed to try other things.



    Sunday, December 2, 2007 5:38 AM
  • DocType doesn't matter we run all of ours with


    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "">


    You don't need to call refresh all you need is


    ReportViewer1.ServerReport.ReportServerUrl = new Uri("http://localhost/Reportserver");

    ReportViewer1.ServerReport.ReportPath = Session["reportpath"].ToString();

    repparams = Session["reportparams"] as List<ReportParameter>;



    Also I recommend that you set ProcessingMode in the ASPX tag. 


    One other idea how is the reportviewer placed in the page and do you have any 3rd party or Ajax control's on the page.

    Sunday, December 2, 2007 7:26 AM
  • Although checking for Ajax code is usually my second guess, I am sorry to tell you this, but doctype *does* matter, at least with master pages and I believe especially when you set the width of the control.


    See here  or or or


    ... or many other threads.  I first learned about it here:






    Hello Chris,

    I think this is that the Report Viewer Control rendered the HTML code does not matc the XHTML artifact.

    This issue is a known issue of the Report Viewer Control. I got this
    workaround from the product team and they do not provide more detailed
    information on this issue.

    Anyway, I am glad to discuss more detail on this issue but since this is
    relate the Report Viewer Control Code, I could not provide more detailed
    information now. Thank you for your follow up.

    Wei Lu
    Microsoft Online Community Support





    Sunday, December 2, 2007 3:58 PM
  • I have honestly never ran into the doctype problem before.  We don't set width by % and we don't use the reportprompts area either(replaced with ajax and/or silverlight).


    Sunday, December 2, 2007 7:32 PM
  • Hi Guys,

    Actually problem is with the Viewer control. Just i removed the viewer control, aspx page and again i have taken fresh page and control. Now those are working fine.

    This solved my problem........ Thanks to all.

    Monday, July 14, 2008 11:20 AM
  • The Ajax Update Panel is the culprit in my case.  When i commented these Ajax controls, Report viewer showed up the results.

    Typically, the quantum of the data being queried is relevant in this case as well, because the AJAX was good with 1 millions records query and did not show up records when the size was 2 million records. I think internally the session timer would expire by the time 2 million records are queried.

    Thanks Lisa for pointing it out; it saved a day of my (Frustrating) labor.

    Friday, May 25, 2012 4:42 PM
  • Thank you....Thank you...Thank you for this discussion thread.  I have turned the internet upside down trying to find the solution to why my report shows records in the counter but there are no lines returned.  The answer is DO NOT use percent for the height and width of the control settings.  Use px instead....


    Tuesday, February 11, 2014 11:08 PM