FIX: Toolbar Events Fire Differently When Using Dock MethodID: Q141425 3.00 3.00b WINDOWS kbtool kbbuglist kbfixlist The information in this article applies to:
SYMPTOMSThe BeforeDock, Undock, and AfterDock events are not triggered in the same order when a toolbar is docked interactively versus when a toolbar is docked under program control. When the dock position of a toolbar is changed interactively, the events fire in the following order:
When the dock position of a toolbar is changed under program control with
the Dock method, the events fire in the following order:
STATUSMicrosoft has confirmed this to be a problem in the Microsoft products listed at the beginning of this article. This problem has been fixed in Visual FoxPro 5.0 for Windows.
WORKAROUNDThere is no way to prevent the events from occurring, or to trigger the events under program control. However, if you have code for the BeforeDock and Undock methods and do not want to call it when the Dock method is executed, follow these steps: 1. Add a property to the class called lDockit. 2. In the Dock method, set the value of this property to true (.T.) as in 3. In the event handler for BeforeDock, add the following:
4. In the event handler for Undock, add the following:
MORE INFORMATION
Steps to Reproduce Problem1. Type CREATE CLASS in the Command window. 2. In the Create Class dialog box, enter the following information to 3. In the Class Designer, enter the following line for the AfterDock,
4. Save the class.
5. Create a toolbar object by typing the following code in the Command 6. Use the mouse to dock the toolbar. The BeforeDock and AfterDock events
7. From the Command window, call the Dock method to move to another docked
KBCategory: kbtool kbbuglist kbfixlist
KBSubcategory: FxtoolFormdes VFoxWin buglist3.00 buglist3.00b fixlist5.00
Additional reference words: 3.00 3.00b
|
Last Reviewed: February 23, 1997 © 2000 Microsoft Corporation. All rights reserved. Terms of Use. |