BUG: Controls Cannot Be Added to Toolbar ProgrammaticallyLast reviewed: August 5, 1997Article ID: Q172343 |
The information in this article applies to:
SYMPTOMSWith Visual Basic, you may add controls to a Toolbar control by creating a placeholder button on the toolbar and then setting the control to the same position. If you use the Comctl32.ocx that ships with Visual Studio 97 and Visual Basic 5.0, the control may unexpectedly appear behind the toolbar.
RESOLUTIONTo work around this problem, create a pause with DoEvents after you set all the controls in place and then set the Toolbar control to the bottom of the ZOrder. NOTE: This workaround does not apply to non-windowed controls, such as a Label or a Shape. To use this workaround with non-windows controls, the controls must be contained in a PictureBox. STATUSMicrosoft has confirmed this to be a bug in the Microsoft products listed at the beginning of this article. We are researching this bug and will post new information here in the Microsoft Knowledge Base as it becomes available.
MORE INFORMATION
Steps to Reproduce Behavior
Keywords : PrgCtrlsStd vb5all Version : WINDOWS:1.0,4.0,5.0 Platform : WINDOWS Issue type : kbbug |
================================================================================
© 1998 Microsoft Corporation. All rights reserved. Terms of Use. |