Calculator Truncates Hexadecimal Numbers Converted from Decimal

ID: Q187514


The information in this article applies to:


SYMPTOMS

When you use the Calculator tool to convert a decimal number to a hexadecimal number, some digits in the hexadecimal number may be missing. As a result, if you convert back to a decimal number, the number is different from what you originally typed.


CAUSE

This problem can occur if you attempt to convert a very large decimal number to hexadecimal. If the hexadecimal equivalent of a decimal number is more than eight digits, only the eight rightmost digits are displayed.


RESOLUTION

To prevent this problem from occurring, do not use Calculator to convert large decimal numbers to hexadecimal.

To work around this problem so that you receive an error message if the hexadecimal number is too large, use the version of Calculator included with Windows 95. To do so, follow these steps:

  1. Click Start, point to Find, and then click Files Or Folders.


  2. In the Named box, type calc.exe, and then click Find Now.


  3. In the list of found files, right-click the Calc.exe file, and then type a new name for the Calc.exe file (such as Calc.xxx).


  4. Extract a new copy of the Calc.exe file from your original Windows 95 disks or CD-ROM into the Windows folder. The Calc.exe file is located in the following locations:




STATUS

Microsoft has confirmed this to be a problem in Microsoft Windows 98.


MORE INFORMATION

For example, the hexadecimal equivalent of "12345678901" is "2dfdc1c35." When you convert "12345678901" to a hexidecimal number using Calculator, the result is "dfdc1c35" (the 2 is truncated). When you convert "dfdc1c35" back to a decimal number, the number is changed to "3755744309."

Additional query words: hex


Keywords          : kbtool win98 
Version           : WINDOWS:98
Platform          : WINDOWS 
Issue type        : kbprb 

Last Reviewed: February 5, 1999