DOCERR: ControlBox Property Not Available at Run Time Per HelpID: Q143064 3.00 3.00b WINDOWS
The information in this article applies to:
SUMMARYThe Visual FoxPro Help file topic for the ControlBox property of a form or toolbar says that the ControlBox property is available at design time and read-only at run time. This is incorrect; the ControlBox property is available at design time and at run time.
MORE INFORMATIONThe ControlBox property can be changed to true (.T.) or false (.F.). The default value is true, which displays the minus sign in Windows 3.1 and Windows NT or an icon in Windows 95 on the upper left corner of the form. A user can use the control box to move, resize, maximize, minimize, or close a form. The ControlBox property has no effect in Visual FoxPro for Macintosh. Setting the ControlBox property to false makes the minus sign or icon disappear, so the form can't be changed or closed using the control menu. On a toolbar, setting the ControlBox property to false disables the minus sign in Windows 3.1 and Windows NT or the X box in Windows 95 that closes the toolbar. So if you want, you can disable the control box of a form or toolbar at run time until a user has performed a certain task. Then you can allow them to change or close a form or toolbar. Following is an example showing how to toggle the ControlBox property in a form at run time from true to false.
Step-by-Step Procedure to Toggle ControlBox Property1. Create a new form, and place a command button on it. 2. In the click event of the command button, type the following code:
3. Run the form, and note that there is an icon (a FoxPro head) in Windows
4. Click the icon or minus sign, and note that there will be a drop down
Additional reference words: 3.00 3.00b VFoxWin
KBCategory: kbdocerr kbhowto
KBSubcategory: FxtoolFormdes
|
Last Reviewed: May 22, 1998 © 2000 Microsoft Corporation. All rights reserved. Terms of Use. |