Microsoft KB Archive/49810: Difference between revisions

From BetaArchive Wiki
m (Text replacement - "<" to "<")
m (Text replacement - ">" to ">")
Line 13: Line 13:
The following is an example of such a macro:
The following is an example of such a macro:


<<set a=3.00>&gt; <<a>&gt;
<<set a=3.00>> <<a>>


This macro returns the number 3 instead of 3.00. It works properly if the number contains significant digits to the right of the decimal (for example, 3.100 returns 3.100 within a macro). This feature works properly in Word version 4.00.
This macro returns the number 3 instead of 3.00. It works properly if the number contains significant digits to the right of the decimal (for example, 3.100 returns 3.100 within a macro). This feature works properly in Word version 4.00.

Revision as of 10:28, 21 July 2020

Word: Returns Real Numbers as Integers in a Macro

PSS ID Number: Q49810 Article last modified on 11-02-1994

5.00 5.50

MS-DOS

SUMMARY

In Word version 5.00, if a real number is set in a macro using the SET command with all zeros appearing in the decimal locations, or a calculation is done in a macro producing a real number with zeros appearing in all the decimal locations, the number is returned as an integer.

The following is an example of such a macro:

<<set a=3.00>> <<a>>

This macro returns the number 3 instead of 3.00. It works properly if the number contains significant digits to the right of the decimal (for example, 3.100 returns 3.100 within a macro). This feature works properly in Word version 4.00.

Microsoft has confirmed this to be a problem in Word version 5.00. This problem was corrected in Word version 5.50.

KBCategory: kbother kbmacro KBSubcategory: Additional reference words:

============================================================================= Copyright Microsoft Corporation 1994.