Article ID: 261193 - View products that this article applies to.
This article was previously published under Q261193
When using the Show method of Data Report to preview the report, the page orientation defaults to the default printer settings on the local computer. Therefore, if the orientation of the default printer settings is set to Portrait of standard Letter paper and your report width is more than 8.5 inches wide, the following error occurs:
Report Width is Larger than the Paper Width
This error occurs because the width of your report exceeds the maximum width specified by the default printer settings. The width of the report is determined by taking the sum of the RightMargin, LeftMargin, and ReportWidth properties.
When a report prints or displays, the default printer settings in the Printers Folders are used to determine the layout of the report. Because the Printer object in Visual Basic cannot modify the default printer settings, if your default printer orientation is set to Portrait of standard Letter paper and you design a report that extends beyond 8.5 inches wide, the preceding error occurs.
NOTE: The LeftMargin, RightMargin, and ReportWidth properties are denoted in twips, and 1440 twips equal 1 inch.
Microsoft Visual Studio 6.0 Service Pack 4 and later service packs include a new property called Orientation for Data Report. The value for this property is:
When you use this new Orientation property in Visual Studio 6.0 Service Pack 4, you may encounter the error below:
DataReport1.Orientation = rptOrientLandscape DataReport1.Show
To fix this error, delete the values for DataMember and DataSource properties of the Data Report and reassign these two properties with the original values.
Method or Data member not found.
Microsoft has confirmed that this is a bug in the Microsoft products that are listed at the beginning of this article. This bug was corrected in the next service pack for Visual Studio 6.0.
For additional information about Visual Studio service packs, click the following article numbers to view the articles in the Microsoft Knowledge Base:
194022To download the latest Visual Studio service pack, visit the following Microsoft Web site:
(http://support.microsoft.com/kb/194022/EN-US/ )INFO: Visual Studio 6.0 Service Packs, What, Where, Why
(http://support.microsoft.com/kb/194295/EN-US/ )HOWTO: Tell That a Visual Studio Service Pack Is Installed
Steps to Reproduce Behavior
Steps to Fix the Problem in Visual Studio 6.0 Service Pack 4
This article fixes the problem addressed in the following article:
(http://support.microsoft.com/kb/197915/EN-US/ )PRB: Report Width is Larger than the Paper Width