BUG: ScrollBar Controls Exhibit Paint Problems When Code Is Executed in Change Event (251321)
The information in this article applies to:
- Microsoft Visual Basic Standard Edition, 32-bit, for Windows 4.0
- Microsoft Visual Basic Professional Edition, 16-bit, for Windows 4.0
- Microsoft Visual Basic Professional Edition, 32-bit, for Windows 4.0
- Microsoft Visual Basic Enterprise Edition, 16-bit, for Windows 4.0
- Microsoft Visual Basic Enterprise Edition, 32-bit, for Windows 4.0
This article was previously published under Q251321 SYMPTOMS
In Microsoft Visual Basic, the intrinsic HScrollBar and VScrollBar controls experience painting problems if the mouse is moved off the control prior to the completion of code execution in the Change event.
RESOLUTION
To work around this behavior, the scrollbar control can be disabled at the start of the Change event. Once the code execution is complete, the control can then be enabled again.
Private Sub HScroll1_Change()
HScroll1.Enabled = False
' place your code here
HScroll1.Enabled = True
End Sub
STATUSMicrosoft has confirmed that this is a bug in the Microsoft products that are listed at the beginning of this article.
Modification Type: | Major | Last Reviewed: | 6/24/2004 |
---|
Keywords: | kbBug kbCtrl kbnofix kbScrollBar KB251321 |
---|
|