PRB: Print Function Evaluation Order Has ChangedLast reviewed: September 30, 1997Article ID: Q141879 |
The information in this article applies to:
SYMPTOMSThe order of evaluation of the arguments to the Print statement differs in Visual Basic 3.0 and Visual Basic 4.0.
CAUSEAll products that use Visual Basic for Applications, including Visual Basic 4.0, evaluate all function calls contained within a Print statement first, before any printing is done. Visual Basic 3.0 evaluates functions while executing the Print statement.
STATUSThis behavior is by design. The order of evaluation of multiple functions within an expression is undefined and may change from version to version. This is documented at the end of the online Help for the Function statement.
MORE INFORMATION
Steps to Reproduce Behavior
Print M Test(M) M Test(M) Visual Basic 3.0 1 2 2 3 Visual Basic 4.0 3 2 3 3Visual Basic 3.0 evaluates functions while processing the Print statement. Because Visual Basic 4.0 uses Visual Basic for Applications, all functions are evaluated first, before any printing is done. Keywords : IAPVBA VB4ALL VB4WIN vbwin GnrlVb kbprg Technology : kbvba Version : WINDOWS:4.0 Platform : WINDOWS Issue type : kbprb |
================================================================================
© 1998 Microsoft Corporation. All rights reserved. Terms of Use. |