PC Forms: Incorrect Data Printed from SubformLast reviewed: November 1, 1995Article ID: Q107357 |
The information in this article applies to:
SUMMARYWhen you print a custom form created using version 1.0 of Microsoft Electronic Forms Designer, information in subforms may not print as expected. When E-Form Caching is turned on, information from a previous instance of the subform may print instead of the current data.
CAUSEThe instructions listed in the "Adding Modal and Modeless Subforms" section (pages 98-102) of the Microsoft Electronic Forms Designer "Developer's Guide" will place code in correct locations for reading subforms. However, it does not provide instructions for properly handling printing of subforms when caching is turned on. The method outlined in the "Developer's Guide" is for the ReadTaggedControls function to be called in the Load event of a subform. When a subform is opened, ReadTaggedControls reads the subform's data from the MEF package. If a custom message is read and the Print command is issued before the subform is opened, the Load event for the subform does not take place. Consequentially, the ReadTaggedControls function is not called to retrieve the subform's data from the package. When caching is turned on, the cached data for the subform is used and will print.
WORKAROUNDTo work around this problem, you must read the subform data from the package when the e-form loads, rather then waiting to read the data when the subform is opened. To do so, perform the following steps to add code to the ReadMessage function defined in the EFORM.BAS file:
|
Additional reference words: 1.00 wrong printed sub form
© 1998 Microsoft Corporation. All rights reserved. Terms of Use. |