Windows 3.0 and Minimum-Sized User-Defined Window

Last reviewed: June 27, 1995
Article ID: Q101152
The information in this article applies to:
  • Microsoft FoxPro for Windows, versions 2.5 and 2.5a

WCOLS() returns a different value depending if FoxPro is running under Windows 3.0 in standard VGA mode or Windows 3.1 standard VGA mode.

If the code below is run in Windows 3.1 standard VGA mode, WCOLS() returns 8, as expected. If the same code is run in Windows 3.0 standard VGA mode, WCOLS() returns 11, which is wider than the requested window size.

This behavior occurs because Windows is enforcing a minimum size.

   DEFINE WINDOW test FROM 1,1 TO 10,10 ;
      SYSTEM FLOAT GROW ZOOM MINIMIZE TITLE 'test' ;
      FONT 'foxfont', 9
   ACTIVATE WINDOW test
   MODIFY WINDOW test CLOSE
   ST=ALLTRIM(STR(WCOLS()))
   WAIT WINDOW ST
   DEACTIVATE WINDOW test
   RELEASE WINDOW test


Additional reference words: FoxWin 2.50 2.50a
KBCategory: kbprg
KBSubcategory: FxprgGeneral


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.

Last reviewed: June 27, 1995
© 1998 Microsoft Corporation. All rights reserved. Terms of Use.