FIX: Masked Edit Tab Order Incorrect If Visible Property FALSE (152603)
The information in this article applies to:
- The Microsoft Foundation Classes (MFC), when used with:
- Microsoft Visual C++, 32-bit Editions 4.0
- Microsoft Visual C++, 32-bit Editions 4.1
- Microsoft Visual C++, 32-bit Enterprise Edition 4.2
- Microsoft Visual C++, 32-bit Professional Edition 4.2
This article was previously published under Q152603 SYMPTOMS
Multiple Masked Edit OLE Controls that are not visible will not retain
their original tab order after they are made visible.
If you insert more than one Microsoft Masked Edit Ole Control into a dialog
resource wrapped by a MFC Class (CDialog, CFormView, CRecordView, or
CDaoRecordView), set the Visible Properties of the Controls to FALSE in the
Resource Editor at design time, and then call the ShowWindow on the
controls, the focus is set to the wrong control.
RESOLUTION
If possible, leave the Visible property of the Microsoft Masked Edit OLE
Control set to TRUE.
If you call SetFocus on the first masked edit control, the focus is set
properly to that control, but if there are any other non-static controls
on the form, they will be inserted before the second masked edit control in
the tab order at run time.
SetWindowPos() can be used to set the z-order of a control. The tab order
in a dialog is synonymous with the Z-order, meaning that a control that is
first in the tab order will have a higher Z-order than a control that
follows it in the-Z order. A control with the WS_CLIPSIBLINGS window style
set that is overlapped by another control will not be painted in the area
that is overlapped. OLE controls have the WS_CLIPSIBLINGS window style set
by default.
STATUS
Microsoft has confirmed this to be a bug in the Microsoft products listed
at the beginning of this article. This bug has been fixed in Visual C++
version 5.0.
Modification Type: | Major | Last Reviewed: | 12/10/2003 |
---|
Keywords: | kbBug kbCtrl kbfix kbusage kbVC500fix KB152603 |
---|
|