Sample Code Browses Fields and Accesses Scroll BarLast reviewed: April 29, 1996Article ID: Q88665 |
The information in this article applies to:
This article contains two methods to incorporate a BROWSE command in another window. The first option does not allow data entry; the second option does.
Method 1The following sample code allows you to move through the browse fields and have access to a scroll bar, but does not allow you to modify the database or close the Browse window without closing the parent window. The program assumes you have a database named TEST.
USE Test DEFINE WINDOW Parent FROM 1,1 TO 15,25 SYSTEM ACTIVATE WINDOW Parent BROWSE NOEDIT NOAPPEND NODELETE ; WINDOW Parent IF LASTKEY()=27 DEACTIVATE WINDOW PARENT ENDIF Method 2The following sample code accomplishes the same result but does not limit your ability to enter data. In the MS-DOS environment, the size parameters should be made smaller, or the following command should be issued first:
SET DISPLAY TO VGA50 USE Test DEFINE WINDOW Parent FROM 1,1 TO 30,45 SYSTEM ACTIVATE WINDOW Parent DEFINE WINDOW Child from 2,2 SIZE 26,37 IN WINDOW Parent BROWSE IN WINDOW Parent WINDOW Child NOWAIT REFERENCES"Creating FoxPro Applications," George F. Goley IV, Que Corporation, 1993, page 244
|
Additional reference words: VFoxWin 3.00 FoxDos FoxWin 2.00 2.50 2.50a
© 1998 Microsoft Corporation. All rights reserved. Terms of Use. |