KnowledgeBase Archive

An Archive of Early Microsoft KnowledgeBase Articles

View on GitHub

Q59723: OS/2 DosFindFirst Code Example Correction; Missing Comma

Article: Q59723
Product(s): See article
Version(s): 7.00 7.10
Operating System(s): OS/2
Keyword(s): ENDUSER | docerr | mspl13_basic
Last Modified: 8-JAN-1991

On Page 525 of the "Microsoft BASIC 7.0: Programmer's Guide" for
Microsoft BASIC Professional Development System (PDS) Versions 7.00
and 7.10, the code example given is missing a comma to delimit the
VARSEG and SADD parameters when invoking the function DosFindFirst%.

The incorrect syntax documented in the manual is as follows:

   x = DosFindFirst%(VARSEG(flname$) SADD(flname$), dirh,_
                    atr, buffer, bufflen, searchcount, reserved)

The correct syntax of the CALL is as follows:

   x = DosFindFirst%(VARSEG(flname$), SADD(flname$), dirh,_
                    atr, buffer, bufflen, searchcount, reserved)

A comma is needed between VARSEG(flname$) and SADD(flname$).

THE INFORMATION PROVIDED IN THE MICROSOFT KNOWLEDGE BASE IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND. MICROSOFT DISCLAIMS ALL WARRANTIES, EITHER EXPRESS OR IMPLIED, INCLUDING THE WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL MICROSOFT CORPORATION OR ITS SUPPLIERS BE LIABLE FOR ANY DAMAGES WHATSOEVER INCLUDING DIRECT, INDIRECT, INCIDENTAL, CONSEQUENTIAL, LOSS OF BUSINESS PROFITS OR SPECIAL DAMAGES, EVEN IF MICROSOFT CORPORATION OR ITS SUPPLIERS HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. SOME STATES DO NOT ALLOW THE EXCLUSION OR LIMITATION OF LIABILITY FOR CONSEQUENTIAL OR INCIDENTAL DAMAGES SO THE FOREGOING LIMITATION MAY NOT APPLY.

Copyright Microsoft Corporation 1986-2002.