• Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint

Troubleshooting

Problems Exporting Reports to HTML

Q1:I receive the message “A Runtime Error has occurred” when I open the ReportName.htm file in IE 5+.
A1: You're likely to encounter errors exporting even moderately complex reports to HTML with the shipping version of ReportML2HTML4.xsl. For example, when you attempt to open rptInventoryByCategory.htm, which you create by exporting Chapter 16's rptInventoryByCategory report, the error message shown in Figure 24.39 appears. Although the message invites you to debug the script, the Microsoft Script Editor can't handle debugging of script within an .xsl file. You ultimately receive a “nocando” message when you click the Script Editor's Break button.

Figure 24.39. Error messages that appear when I open reports saved as XML invite me to debug the problem, which doesn't work.


If the error message contains a hint about the source of the problem, such as 'Sum' in Figure 24.39, open the report in Design view, make a copy, and try removing controls that use the offending method or property. For example, if you remove all text box controls having =Sum(...) expressions from a copy of rptInventoryByCategory, the error no longer occurs. However, the modified Web report's content is less valuable than that of the original. (This report uses Jet's DLookup function to return the Category name value; Jet expressions don't work in Web reports.)

Tip from

When you design reports specifically for export to Web pages, export and test the report's .htm file repeatedly as you add controls. The simpler the expression you use to populate text box controls is, the more likely it is that your report page will open without an error.



PREVIEW

                                                                          

Not a subscriber?

Start A Free Trial


  
  • Creative Edge
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint