Editing General Fields in FoxPro Screen Builder

Last reviewed: April 29, 1996
Article ID: Q95303
The information in this article applies to:
  • Microsoft FoxPro for Windows, versions 2.5x, 2.6, 2.6a

SUMMARY

A general field cannot be used as a GET field in the Screen Builder. The Screen Builder will automatically generate an @ ... SAY command when the Picture tool is chosen to place a picture on the screen form. To allow editing of the general field, create an invisible button with a VALID clause on top of the picture, as illustrated below.

MORE INFORMATION

The following example assumes that there is an open database named TEST.DBF that contains a general field named PICT.

  1. From the File menu, choose New.

  2. In the File Type dialog box, select Screen, and choose the New button.

  3. When the UNTITLED.SCX screen appears, select the Picture tool at the bottom of the toolbox.

  4. In the Screen Picture dialog box, select the Field radio button, choose the Field command button, and select PICT from the Field list. Choose OK twice to return to the Screen Builder.

  5. Click the Button tool, and place a push button on the top-left corner of the picture.

  6. In the Type box, select Invisible, give the button a name in the Variable prompt, select the Valid Clause button, and in the code snippet window, type "MODIFY GENERAL PICT" (without the quotation marks). Choose OK twice to return to the Screen Builder.

  7. Resize the button so that it covers almost the whole picture.

  8. Save the screen as TEST.SCX and generate TEST.SPR.

  9. Run TEST.SPR and the screen will appear. Double-clicking the picture will invoke the general field window and the existing picture may be edited, cleared, or replaced with a new picture.


Additional reference words: FoxWin 2.50 2.50a 2.50b 2.60 2.60a bit map bmp
pcx
KBCategory: kbprg
KBSubcategory: FxtoolSbuilder


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: April 29, 1996
© 1998 Microsoft Corporation. All rights reserved. Terms of Use.