Microsoft KB Archive/72421

= Compiled /FPa, NOW# Gives Incorrect Results After First Call =

Article ID: 72421

Article Last Modified on 10/20/2003

-

APPLIES TO


 * Microsoft BASIC Professional Development System 7.1
 * Microsoft BASIC Professional Development System 7.0

-



This article was previously published under Q72421



SYMPTOMS
When using the NOW# function (which returns a serialized current date and time representation) with alternate math (BC /FPa), NOW# may work erratically or fail entirely after the first call.



STATUS
Microsoft has confirmed this to be a bug with the Date/Time add-on library included with Microsoft Basic Professional Development System (PDS) for MS-DOS and MS OS/2, versions 7.0 and 7.1. This problem was corrected in Microsoft Visual Basic version 1.0 for MS-DOS.



MORE INFORMATION
The following program demonstrates this problem. The first line displayed on the screen uses the NOW# function and is not updated correctly. The second line uses the TIME$ function and shows the correct time.

Code Sample: NOW.BAS
Compile this example as follows: BC /FPa /O now.bas ; Link this example as follows: LINK now,,,DTFMTAR.LIB ; '$INCLUDE: 'datim.bi' CLS PRINT &quot;Press 'q' to quit&quot; WHILE INKEY$ <> &quot;q&quot; LOCATE 1, 1: PRINT Now# LOCATE 2, 1: PRINT TIME$ WEND

Additional query words: VBmsdos BasicCom 7.00 7.10 b_vbmsdos 1.00 SR# S910520- 35 buglist7.00 buglist7.10 fixlist1.00

Keywords: KB72421

-

[mailto:TECHNET@MICROSOFT.COM Send feedback to Microsoft]

© Microsoft Corporation. All rights reserved.