none
Reportviewer 10.0.0 Async problem RRS feed

  • Question

  • I have the new ReportViewer control running in my Visual Studio 2010 RC project against a remote SSRS Server. Everything works fine if I keep the associated ScriptManager EnablePartialRendering="False" but if I set it to "True" (which provides a much better user experience) I get a JavaScript error stating that  "'this._docMapSplitter' is null or not an object" The messed up part is that this only happens in Internet Explorer (Safari, Firefox, and Opera are fine) and my reports do not use a document map. If I ignore the error on the client side everything works fine. Is there a way to get around this error by either trapping and discarding on the client or turning the document map capability off? I assume the other browsers don't have a problem because the "feature" degrades.

    TIA
    Wednesday, March 17, 2010 10:37 PM

Answers

  • I have not seen this error previously and it certainly sounds like a bug in the product.  The document map is supported in all browsers beginning with VS 2010, so I suspect something else is going on.  Would you be willing to file a bug at http://connect.microsoft.com that includes the ASPX page that is causing the problem?  I would definitely like to investigate this issue further.
    Monday, March 22, 2010 4:27 AM
    Moderator

All replies

  • Hi dotnutter,
    I performed a test at my side with VS 2010 Ultimate RC but could not reproduce your issue.  Everything works fine with the property "AsyncRendering" set to True. The Js error regarding "_docMapSplitter" looks related to the fact that some of your report items defined the documentmaplabel property. Could you please open your .RDL file in "View code" mode and use CTRL+F to check if there is any words containing "documentmap"?

    Currently you may try the following two methods to see if you can resolve this issue:
    1. Go to IE->Tools->Internet Options->Advanced to make sure that the following two options are checked:
        Disable script debugging (Internet Explorer)
        Disable script debugging (Other)

    2. Try recreating a new report.


    Please remember to mark the replies as answers if they help and unmark them if they provide no help
    Friday, March 19, 2010 6:00 AM
    Moderator
  • Thanks for your response Charles. Option one is not viable as these reports are viewed by a user base who may or may not be able to mimic those setting changes. I have opened each report in code mode and searched for documentmaplabel and it is not present in any of the reports. These reports are built in VS2008 and hosted on SSRS 2008, do I have an incompatibility? I don't need document maps at all so if I could write some Client JScript that trapped and discarded this particular error I would be OK for now. Is there a client side onError event I can hook? I have looked around but the documentation I have found doesn't lead me in the right direction.

    Another bit of info: This only happens if I change a parameter on these reports or otherwise cause the report viewer to reload a previously loaded report. The first load of any report causes no errors. It is subsequent refreshes of any report that throws the javascript error.

    Friday, March 19, 2010 2:59 PM
  • I have not seen this error previously and it certainly sounds like a bug in the product.  The document map is supported in all browsers beginning with VS 2010, so I suspect something else is going on.  Would you be willing to file a bug at http://connect.microsoft.com that includes the ASPX page that is causing the problem?  I would definitely like to investigate this issue further.
    Monday, March 22, 2010 4:27 AM
    Moderator
  • I have one more piece of information to add. This is reproducible by me only when using IE 8 in compatibility mode. Users have reported the problem with IE 7 but I don't see it consistently. I have seen script errors during development but they were always resolvable. I cannot verify with absolute confidence that users are seeing the error referencing the doc map. I can say that on my dev machine (Windows 7 - VS 2010 RC - IE 8 compat) the error happens every time I refresh an already loaded report. I will file a bug.
    Monday, March 22, 2010 10:07 PM
  • I am experiencing the same error.  In my case, I have a website containing a report which was created originally with VS2008 but has been upgraded to VS2010.  The report is running in local mode.  Also, for me the error occurs only when the page is loaded.  If I ignore the error everything works fine, including post-backs during which the report parameters were changed or the report data was reloaded. 

    The script error shown on the browser is:

     

    Line: 1150
    
    Char: 9
    
    Error: 'this._docMapSplitter' is null or not an object
    
    Code: 0
    
    URL: ...../Reserved.ReportViewerWebControl.axd?OpType=Resource&Version=10.0.30319.1&Name=ViewerScrip
    
    

    If I am running the report in VS2010, it opens up the page Reserved.ReportViewerWebControl.axd?OpType=Resource&Version=10.0.30319.1&Name=ViewerScript and it shows the same "'this._docMapSplitter' is null or not an object" error in the line:

        if (this._docMapSplitter._getCollapsable() || makeVisible)
    

    Similar to dotnutter, I am not using document maps in my report.  In addition, I call the same rdlc file from 2 different webpages:

    One page  expects few session variables, containing some IDs to be used as the SQL query filters, to be previously set.  Tthis page is reachable only via another, which takes care of creating the session variables. 

    The second page with this same report allows the user to enter some dates and other values which I use for my SQL query to filter the results that will be shown in the report.  Both of these webpages contain an UpdatePanel wherein lie additional controls whose values are eventually passed to the report parameters.  Those just affect formatting options (set areas of the report visible/hidden, etc).  Finally, both pages contain a "View Report" button which, when clicked, calls code to pass the user's selections into the report and refresh it. 

    Despite their great similarities, however, only the former of these 2 webpages has issues! Again, the only difference between these reports is that the latter page has a few extra controls in it and the SQL Datasources' parameters are bound to those controls, while the former page has fewer controls and the SQL Datasources' parameters are bound  to session variables...

    Wednesday, April 28, 2010 3:01 PM
  • An update: As I mentioned in my previous post, I have 2 near-identical reports, one getting SQL filters via controls on the page, which works fine, and one getting them via session variables, which gives the error.  I looked more into the differences between the two and found a little difference in the code-behind.  Namely, since the report was receiving all the SQL parameters via session variables and it really had all the necessary information to render the report, at PageLoad I made a call to go ahead and pass a default set of Report Parameters, then render the report. 

    If I comment out this call in Page_Load, the webpage loads fine with no errors, and clicking my "View Report" button (which makes the same call to pass the report parameters and render the report) works fine.  In other words, it is just a matter of WHEN in the page's loading cycle the report is accessed.

    Nevertheless, something still does not make sense.  I tried changing the location where I make  this call.  I tried Page_LoadComplete and ReportViewer1_PreRender, but did no good.  Additionally, I traced through in debug mode and noticed that the code ran all the way through with no errors, but the refreshing the report requires a post-back.  The error occurs during this post-back!  This is particularly strange :/ What is the difference between the page loading fully, the user clicking on a button, the button's code loading the report parameters, calling the report refresh, and posting back versus the page loading up until Page_LoadComplete is fired, then loading the  report parameters, calling the report refresh, and posting back in this manner?  Why does the button-click work with no errors but the Page_LoadComplete throws errors?  And why is it that this issue never occurred in VS2008 and .Net Framework 3.5?

    I look forward to your responses.  Thank you.

    Wednesday, April 28, 2010 4:37 PM
  • Same issue here, using Report Viewer 2010 RTM.

    Problem seems related, as already spotted, to IE 8 with Compatibility View enabled.

    Exception data, from IE debug window (this is a javascript problem):

    Line: 1150

    Error: 'this._docMapSplitter' is null or not an object

     //NOT INTENDED FOR PUBLIC USE. Call SetDocMapAreaVisibility to set the DocMap Visibility
     //This updates the HTML DOM to collapse or show the DocMapArea
     //Call this when the visiblity on the DocMap has changed so the sizing can be correctly calculated.
     //'hideEverything' == true, causes the entire DocMap UI to be 'display:none' rather than 0px wide. 
     //This is necessary for resize calculations. IE6 and 7 standards mode need to use 0px wide drawing, so the table cells
     //in the same TR are correctly calculated (extra 1px appears on the right-hand-side)
     _UpdateDocMapAreaUIVisibility: function(hideEverything)
     {
      var docMapCells = this.GetDocMapCells();
    
      var makeVisible = false;
      if (!hideEverything)
       makeVisible = !this._docMapSplitter._getCollapsed() && docMapCells.hasNodes;
    
      var isVisible = makeVisible;
      if (!hideEverything)
      {
       // Use 0px wide to show everything rather than hiding the DocMap, if there are any doc map nodes
       makeVisible = docMapCells.hasNodes;
      }
    
      // Document map visibility
      if (docMapCells.docMapHeadCell)
      {
       _$RVCommon.SetElementVisibility(docMapCells.docMapHeadCell, makeVisible);
      }
      _$RVCommon.SetElementVisibility(docMapCells.docMapCell, makeVisible);
    
      // Splitter visibility
      // ******************* Next is Line 1150, where _docMapSplitter is null, didn't get initialized at load
      if (this._docMapSplitter._getCollapsable() || makeVisible)
      {
       if (docMapCells.splitterDocMapHeadCell)
        _$RVCommon.SetElementVisibility(docMapCells.splitterDocMapHeadCell, docMapCells.hasNodes);
       _$RVCommon.SetElementVisibility(docMapCells.splitterDocMapCell, docMapCells.hasNodes);
      }
    
      if (!hideEverything)
      {
       var size = 0;
       if (isVisible)
       {
        //If the DocMap is visible, use the splitter size to set sizing.
        size = this._docMapSplitter._getSize();
        if (isNaN(size))
        {
         //If not calculated, ask the UI for the current size available (won't be from a previous call)
         size = docMapCells.docMapCell.style.width;
        }
       }
       this._UpdateDocMapAreaUIWidth(size);
      }
     },

     

     

     

    Ignoring JavaScript error causes no problem to rendering and report functionality.
    Same error doesn't happen if IE 8 is not in Compatibility View.
    Friday, April 30, 2010 10:13 AM
  • Andrea, do you have any other javascript (or Ajax) in your page?

    I have finally managed to make the error not appear in my pages, though mine is NOT a good solution and I find it even stranger as to why it even worked. In my page, I had an AJAX UpdatePanel with some controls in it (including divs with runat="server" which may become hidden or visible based on LinkButton clicks).  I also had javascript that got the client's browser window height and stored the value in a HiddenField, and a ReportViewer1_PreRender function which took the value of the HiddenField, Converted it to an int, and used that value calculate and set a good Height for the ReportViewer control.  I was doing that because in VS2008, setting the report height to a % didn't work too well.  Finally, some of the controls in my webpage may be used as parameters for my queries, but most are used as parameters for the report itself.  For those, I have code-behind that sets the report parameters accordingly.

    Here different changes that I tried to the above and the results:

    1) Remove the UpdatePanel (i.e. all the contents that used to be within that panel are now directly in the page's content).  No errors.

    2) Remove the javascript that sets the value to the HiddenField: Error

    3) Remove/comment out the call to resize the report viewer: No error (at this point, I just set the reportviewer height to 90%, and with VS2010 things seem to resize quite well)

    4) Comment out the call to ReportViewer1.LocalReport.SetParameters(prms) [Here, prms is an array of Microsoft.Reporting.WebForms.ReportParameter]: No Error, but also the report will not be rendered as it is missing parameter values.

    What I find really strange is that I can remove the AJAX UpdatePanel, leave the javascript that populates the HiddenField and leave the report viewer's server-side resizing on ReportViewer PreRender and it will work, so from here it seems to be related to some conflict with the UpdatePanel...BUT if I can also leave the AJAX UpdatePanel as is, leave the javascript for the HiddenField as is, then simply remove the ReportViewer's height setting and it will also work.  This makes it seem like an issue with the ReportViewer_PreRender call (which works fine if I remove the AJAX).  All the while, my ReportViewer is NOT inside the UpdatePanel with my other controls. My page looks something like this:

    <%@ Page Language="VB" MasterPageFile="~/MasterPage.master" AutoEventWireup="false"
     CodeFile="abc.aspx.vb" Inherits="abc" %>
    
    <asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" runat="Server">
     <div >
     <div>
     Some input Controls here, including a HiddenField for the window's height.
     <asp:Button ID="Button1" runat="server" Text="View Report" />
     </div>
     <asp:UpdatePanel ID="UpdatePanel1" runat="server">
     <ContentTemplate>
     More Input Controls here, including some tied to AsynchPostBackTriggers and some tied to PostBackTriggers.
     </ContentTemplate>
     <Triggers>
     ...
     </Triggers>
     </asp:UpdatePanel>
     </div>
     <div>
     <rsweb:ReportViewer ShowRefreshButton="False" ID="ReportViewer1" ShowPrintButton="False" runat="server" Font-Names="Verdana" Font-Size="8pt" Height="400px" Width="100%" ShowDocumentMapButton="False" DocumentMapCollapsed="True" PageCountMode="Actual">
     <LocalReport ReportPath="xyz.rdlc" DisplayName="XYZ Report">
     <DataSources>
      <rsweb:ReportDataSource DataSourceId="Sql_XYZ" Name="DataSet_XYZ_DataTable1" />
     </DataSources>
     </LocalReport>
     </rsweb:ReportViewer>
     </div>
     <asp:SqlDataSource ConnectionString="<%$ ConnectionStrings:defaultConnectionString %>" ID="Sql_XYZ" runat="server" SelectCommand="....."
     <SelectParameters>
     ...various control parameters, tied to controls in the area above the reportviewer...
     </SelectParameters>
     </asp:SqlDataSource>
    </asp:Content>
    <asp:Content ID="Content2" ContentPlaceHolderID="OptionsContentPlaceHolder" runat="Server">
     .....
    </asp:Content>
    BTW, my masterpage also contains some javascript and server-side code but none of the master's code seems to be causing issues in other reports!  Anyway, I think my aspx code is pretty straightforward.  In my code-behind, I just change the connection to my SQLDatasource on PageInit.  I remove the ability to export to Excel on PageLoad, I change the height of the report viewer on ReportViewer1_PreRender (simply using ReportViewer1.Height = someNumber), I have code for handling linkbutton and button clicks (mostly hiding/unhiding various divs that have runat="server", either synchronously or asynchronously, as defined by the UpdatePanel), and finally I have a call to "doShowReport" when a user clicks my "View Report" button.  This code looks like:

     Private Sub doShowReport()
     Dim prms() As Microsoft.Reporting.WebForms.ReportParameter
     Dim prmInfoColl As Microsoft.Reporting.WebForms.ReportParameterInfoCollection = ReportViewer1.LocalReport.GetParameters
     Dim i, j As Integer
    
     ReDim prms(prmInfoColl.Count - 1)
     For i = 0 To prmInfoColl.Count - 1
     prms(i) = New Microsoft.Reporting.WebForms.ReportParameter
     prms(i).Name = prmInfoColl(i).Name
     If prmInfoColl(i).Name.Contains("XYZ") Then
      prms(i).Values.Add(XYZTextBox.Text)
     ElseIf prmInfoColl(i).Name.Contains("ABC") Then
      prms(i).Values.Add(ABCTextBox.Text)
     ElseIf ...
     ...
     ...
     Else
      For j = 0 To prmInfoColl(i).Values.Count - 1
      prms(i).Values.Add(prmInfoColl(i).Values(j))
      Next
     End If
     Next
     ReportViewer1.LocalReport.SetParameters(prms)
     End If
     ReportViewer1.LocalReport.Refresh()
     End Sub

    Again, I don't think anything is really out of the ordinary...so I am really surprised that it gives the javascript error when it does, and it stops giving the errors in those various situations that I explained above.

    Andrea Bertolotto: If you do have any additional UpdatePanels in your page, or some other javascript, or if you are programmatically changing the reportviewer's height like I was, I would suggest you try disabling them one by one (or all together) and see if it works.  Even if it is not an acceptable solution for your program, if it causes the error to go away, I would like to know about it (and I'm sure the MSFT Moderators would, too).  It might help us narrow down the issue more, and hopefully come up with a good workaround or fix ;)

    Thanks

    Friday, April 30, 2010 6:44 PM
  • Hello paris2,

    yes, I have UpdatePanels and JavaScript on page. I'll try to remove and change them as proposed. I'm setting report parameters from codebehind too. But height is fixed for me!

    I'll get back asap with my results!

    Friday, April 30, 2010 9:05 PM
  • Hello again paris2,

    I had some interesting debug session inside Report Viewer javascript code. My findings will follow.

    First of all, I have to say I see reported error not on all my reports. None of my reports make use of Document Maps.
    Next thing is my web site is in Compatibility Mode forced by tag "<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7"/>".

    So I started having a look at why only some of my reports does get this problem.
    That happens because only two of my reports allows navigation to other web site pages, by clicking inside some report element. This is a bit strange behavior and doesn't seem related to report problem, but later I found out how these are related.
    So, I can generate a report, click on some element, navigate to another ASPX page and, from there, push the back button in browser to get back to report. This is where javascript bug appears. Basic idea here is having possibility to render report again, without passing from OnAppLoad javascript function.
    This happens on my side, only when I navigate off from my report to another page, because my site is heavily using Ajax, so URL doesn't get modified very easily. Simply pushing a button on report page, or changing some report parameters (I have some dropdownlists), doesn't invalidate page and bug won't appear.

    This is what really happens in Report Viewer client JavaScript (this is code we can look at using IE 8 integrated JavaScript debugger, from handler: Reserved.ReportViewerWebControl.axd?OpType=ResourceVersion=10.0.30319.1Name=ViewerScript).

    First of all, we know the problem is on field named "_docMapSplitter".

    This is where this._docMapSplitter gets initialized:
    OnAppLoad: function()
    {
        [...]
     
        if (!this._docMapSplitter)
        {
            this._docMapSplitter = $get(this.DocMapSplitterId).control;
            [...]
        }

    So, we can place a watch at:
    this._docMapSplitter
    this.DocMapSplitterId

    When bug appears, _docMapSplitter is undefined, so there should be some way to execute code without passing inside OnAppLoad. This is why _docMapSplitter remains uninitialized.

    Having a look at stack trace when bug happens, we can place a breakpoint on:
    OnWindowResize: function()
    {
        this.ResizeViewerReportUsingContainingElement(false);   <---------- breakpoint here
    },

    and follow code execution through next code - keep in mind we are running Internet Explorer 8 in Compatibility View, so, we are emulating Internet Explorer 7 in Standards Mode:

    ResizeViewerReportUsingContainingElement: function(forceRecalculate)
    {
      [...]
    
      // IE 7 standards mode - when the viewer is in an inline element and there is a doc map, IE
      // collapses the width of the entire viewer to the width of the splitter (the fixed width column).
      // To calculate the correct width in this case, hide the splitter and use the width that IE
      // assigns when only percentage width columns are visible.
      if (_$RVCommon.isPreIE8StandardsMode() &&  // IE 7 standards mode     // this is true, we are using IE 8, but in Compatibility View
        this.BaseWidth.indexOf('%') > 0 &&   // Percentage width       // this corresponds to Width attribute in ReportViewer declaration, inside ASPX or ASCX page, it is "100%" in my case
        this.HasSizingRow)           // Not SizeToReportContent   // this.HasSizingRow = true in my case, refers to attribute SizeToReportContent in ReportViewer declaration
      {
        // Hide the doc map
        this._UpdateDocMapAreaUIVisibility(true);                // <------------------- This is where first exception happens, because this._docMapSplitter is undefined
    
        // Revert viewer to its original value
        reportViewer.style.width = this.BaseWidth;
    
        // Calculate parent width and Set width on viewer
        reportViewer.style.width = reportViewer.clientWidth + "px";
    
        // Restore doc map
        this._UpdateDocMapAreaUIVisibility();                 // we get a second exception here, same cause as above (this._docMapSplitter is undefined)
      }
    


    Following above code with step thru in debugger, I know all 3 conditions are true for me:
    browser is in IE 7 Standards mode
    I've declared Width="100%" inside my asp.net report control
    I've not declared attribute SizeToReportContent inside my asp.net report control (this defaults to false and since HasSizingRow is negation of SizeToReportContent, we get another true)
    So we get inside that code block. This is where bug happens, in routine UpdateDocMapAreaUIVisibility.

    So, to reproduce bug we need to:
    set IE 8 in Compatibility View
    declare report in asp.net similar to <rsweb:ReportViewer ID="myReport" runat="server" Height="500px" Width="100%" />
    report doesn't need to include a Document Map, because problem is related to an HTML input type=hidden, that appears to be rendered in every page, even if not used
    render report normally
    find a way to reload page, chaging URL manually and then going back using browser back button or similar way (keep in mind UpdatePanel relations to browser back button)

    On browser back button, we get a page load, and, at first, I get event OnWindowResize called, before OnAppLoad. So _docMapSplitter isn't initialized and function ResizeViewerReportUsingContainingElement fails.
    This is where problem happens: sometimes we get a Resize Events before AppLoad, and things are not correctly initialized there.

    I removed all UpdatePanels and JavaScript from my page, so every report action causes a full postback and I can press back button without leaving report page: problem becomes easily repeatable.
    Probably there are many other ways to get a resize without app load events, and paris2 is surely forcing a resize by hand.

    Once we know in what lines of code exception happens, we can try to bypass it, forcing one of the three conditions to fail:
    using Internet Explorer 8 in Standards Mode (this is unacceptable for me right now - we are in the process of converting HTML to standards)
    declaring report width in sizes not including % symbol. I tried sizing by pixels and error disappear.
    adding attribute to report declaration SizeToReportContent="true". This changes rendering a little, introducing a fixed table in HTML and removed every error.

    Hope this helps,
    Andrea

    Sunday, May 2, 2010 4:35 PM
  • I am facing exact same problem. I am using  ReportViewer 10.0.0.0  VS2008. I am creating Dashboard kind of page so It has 4 reportviewer instances all inside update panel on same page. after spending lot of time I have got on conclusion that there is no problem at all till you have only one ReportViewer on your page,whether its inside update panel or outside.But As soon as you put second ReportViewer instance on page,immediately it starts giving this._docmapsplitter is null  error. I tested same thing on empty page with only reportviewer control on it,and it starts giving error as I drop second instance on same page.I am unable to find solution for this...anybody faced same situation? any ideas or comments?....hope Microsoft is listening.................
    Friday, July 23, 2010 9:42 PM
  • My organisation is looking at M/soft reporting server as an alternative to its current reports software. I have just encountered this error.

    I am using reportviewer in VS 2010. I have 2 web sites using this. The one with the error is using a session variable to filter the reports. The site not using session variables is fine.

    The error occurs in IE8 compatibility mode when selecting another parameter which reloads the report. The error appears to be random. Without compatibility mode the report viewer will sometimes show only scroll bars, at other times rendering the report correctly. My users are not technicaly savvy so this error will be a problem. I have tried the IE>>Tools fix above with no result.

    Is Microsoft looking at a fix for this?

    • Proposed as answer by Hein Swaan Wednesday, July 13, 2011 12:30 PM
    Wednesday, September 22, 2010 3:51 AM

  • Andrea, do you have any other javascript (or Ajax) in your page?

    I have finally managed to make the error not appear in my pages, though mine is NOT a good solution and I find it even stranger as to why it even worked. In my page, I had an AJAX UpdatePanel with some controls in it (including divs with runat="server" which may become hidden or visible based on LinkButton clicks).  I also had javascript that got the client's browser window height and stored the value in a HiddenField, and a ReportViewer1_PreRender function which took the value of the HiddenField, Converted it to an int, and used that value calculate and set a good Height for the ReportViewer control.  I was doing that because in VS2008, setting the report height to a % didn't work too well.  Finally, some of the controls in my webpage may be used as parameters for my queries, but most are used as parameters for the report itself.  For those, I have code-behind that sets the report parameters accordingly.

    Here different changes that I tried to the above and the results:

    1) Remove the UpdatePanel (i.e. all the contents that used to be within that panel are now directly in the page's content).  No errors.

    2) Remove the javascript that sets the value to the HiddenField: Error

    3) Remove/comment out the call to resize the report viewer: No error (at this point, I just set the reportviewer height to 90%, and with VS2010 things seem to resize quite well)

    4) Comment out the call to ReportViewer1.LocalReport.SetParameters(prms) [Here, prms is an array of Microsoft.Reporting.WebForms.ReportParameter]: No Error, but also the report will not be rendered as it is missing parameter values.

    What I find really strange is that I can remove the AJAX UpdatePanel, leave the javascript that populates the HiddenField and leave the report viewer's server-side resizing on ReportViewer PreRender and it will work, so from here it seems to be related to some conflict with the UpdatePanel...BUT if I can also leave the AJAX UpdatePanel as is, leave the javascript for the HiddenField as is, then simply remove the ReportViewer's height setting and it will also work.  This makes it seem like an issue with the ReportViewer_PreRender call (which works fine if I remove the AJAX).  All the while, my ReportViewer is NOT inside the UpdatePanel with my other controls. My page looks something like this:

     

    <%@ Page Language="VB" MasterPageFile="~/MasterPage.master" AutoEventWireup="false"
     CodeFile="abc.aspx.vb" Inherits="abc" %>
    
    <asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" runat="Server">
     <div >
     <div>
     Some input Controls here, including a HiddenField for the window's height.
     <asp:Button ID="Button1" runat="server" Text="View Report" />
     </div>
     <asp:UpdatePanel ID="UpdatePanel1" runat="server">
     <ContentTemplate>
     More Input Controls here, including some tied to AsynchPostBackTriggers and some tied to PostBackTriggers.
     </ContentTemplate>
     <Triggers>
     ...
     </Triggers>
     </asp:UpdatePanel>
     </div>
     <div>
     <rsweb:ReportViewer ShowRefreshButton="False" ID="ReportViewer1" ShowPrintButton="False" runat="server" Font-Names="Verdana" Font-Size="8pt" Height="400px" Width="100%" ShowDocumentMapButton="False" DocumentMapCollapsed="True" PageCountMode="Actual">
     <LocalReport ReportPath="xyz.rdlc" DisplayName="XYZ Report">
     <DataSources>
     <rsweb:ReportDataSource DataSourceId="Sql_XYZ" Name="DataSet_XYZ_DataTable1" />
     </DataSources>
     </LocalReport>
     </rsweb:ReportViewer>
     </div>
     <asp:SqlDataSource ConnectionString="<%$ ConnectionStrings:defaultConnectionString %>" ID="Sql_XYZ" runat="server" SelectCommand="....."
     <SelectParameters>
     ...various control parameters, tied to controls in the area above the reportviewer...
     </SelectParameters>
     </asp:SqlDataSource>
    </asp:Content>
    <asp:Content ID="Content2" ContentPlaceHolderID="OptionsContentPlaceHolder" runat="Server">
     .....
    </asp:Content>
    
    BTW, my masterpage also contains some javascript and server-side code but none of the master's code seems to be causing issues in other reports!  Anyway, I think my aspx code is pretty straightforward.  In my code-behind, I just change the connection to my SQLDatasource on PageInit.  I remove the ability to export to Excel on PageLoad, I change the height of the report viewer on ReportViewer1_PreRender (simply using ReportViewer1.Height = someNumber), I have code for handling linkbutton and button clicks (mostly hiding/unhiding various divs that have runat="server", either synchronously or asynchronously, as defined by the UpdatePanel), and finally I have a call to "doShowReport" when a user clicks my "View Report" button.  This code looks like:

     

     Private Sub doShowReport()
     Dim prms() As Microsoft.Reporting.WebForms.ReportParameter
     Dim prmInfoColl As Microsoft.Reporting.WebForms.ReportParameterInfoCollection = ReportViewer1.LocalReport.GetParameters
     Dim i, j As Integer
    
     ReDim prms(prmInfoColl.Count - 1)
     For i = 0 To prmInfoColl.Count - 1
     prms(i) = New Microsoft.Reporting.WebForms.ReportParameter
     prms(i).Name = prmInfoColl(i).Name
     If prmInfoColl(i).Name.Contains("XYZ") Then
     prms(i).Values.Add(XYZTextBox.Text)
     ElseIf prmInfoColl(i).Name.Contains("ABC") Then
     prms(i).Values.Add(ABCTextBox.Text)
     ElseIf ...
     ...
     ...
     Else
     For j = 0 To prmInfoColl(i).Values.Count - 1
     prms(i).Values.Add(prmInfoColl(i).Values(j))
     Next
     End If
     Next
     ReportViewer1.LocalReport.SetParameters(prms)
     End If
     ReportViewer1.LocalReport.Refresh()
     End Sub
    

    Again, I don't think anything is really out of the ordinary...so I am really surprised that it gives the javascript error when it does, and it stops giving the errors in those various situations that I explained above.

    Andrea Bertolotto: If you do have any additional UpdatePanels in your page, or some other javascript, or if you are programmatically changing the reportviewer's height like I was, I would suggest you try disabling them one by one (or all together) and see if it works.  Even if it is not an acceptable solution for your program, if it causes the error to go away, I would like to know about it (and I'm sure the MSFT Moderators would, too).  It might help us narrow down the issue more, and hopefully come up with a good workaround or fix ;)

    Thanks

     

    Apart from what paris has said, which I tried and was successful in getting rid of the this.__docmapsplitter error, is that:

    You can keep your ajax update panel, height, width.

    I gave Height & Width as relative values i.e. in percentages. I used width="100%" & height="100%".

    But referring to paris setting it to 90% or something didn't worked for me.

    When removed size settings, report rendered properly, but again, the auto-generated size of report was too small & scrolling reports is bad user experience.

    Thus I gave absolute values to size attributes like : 

    width="800px"

    height="1000px"

    & this worked. Maybe the relative values are causing some issues in rendering.


    -- Patel Pinakin
    Wednesday, June 1, 2011 9:00 AM
  • <html>
    <head>
      <!-- Mimic Internet Explorer 7 -->
      <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" >
      <title>My webpage</title>
    </head>
    <body>
      <p>Content goes here.</p>
    </body>
    </html>

    Set  <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" >
    in the Header of the page as shown above.

    This will resolve the problem

     

    Anil Madan

     

     

     

     


    Thursday, July 21, 2011 7:59 PM
  • Unless I am mistaken I have not seen a solution to this problem.

    Mine is similar. I have an ASP web app which uses ReportViewer to open a SSRS matrix report. In the design of the matrix report I have created two buttons (Expand and Collapse). The Expand button expands the data rows on the report and the Collapse button collapses the rows so that you see only the high level summary row for each grouping. The expand and collapse buttons work by executing the report again and passing a parameter to the SSRS report telling it to display in either the expanded or collapsed view. It is at this point that I get the error described in the first posting of this string.

    Is there a solution? 


    Randy Harding
    Friday, August 26, 2011 6:22 PM
  • Even i faced this problem , and got with solution .

    its not with the update panel , its rendering problem, if u give either of Height and width size in percentage u will get this error.

    Set them using px, the problem will be solved.  

    I had reportview with Height = 350Px and width = 99% then i got this probelm . I made it to width with 1000Px its working perfectly fine. no error.

    hope this is helpful.

    • Proposed as answer by boljug Saturday, September 22, 2012 5:48 PM
    Wednesday, February 22, 2012 6:55 AM