VBcoders Browse New Submit Contact Sign In

No account? Register free

Forgot password?

Frame 'flickering' in Windows XP Goodbye

gibra  (6 Submissions)   Windows API Call/Explanation   VB Script   Intermediate   Wed 3rd February 2021

This function change the CommandButton style to a BS_GROUPBOX to transform it like a Frame control! This solve many problems (bad drawning controls, flickering, etc.).

Assumes
When you use a Frame control on Windows XP where Themes is active (XP Style), there is some problems: 1) OptionButton is draw black 2) CommandButton is draw with black border 3) all controls contained on the frame 'flickering' when you move mouse over them. This code show how to change a CommandButton style and use it like a Frame control.

API Declarations
'-----------------------------------------------
'Module BAS declarations:
'-----------------------------------------------
Private Declare Function SendMessage Lib "user32" Alias "SendMessageA" ( _
ByVal hWnd As Long, _
ByVal wMsg As Long, _
ByVal wParam As Long, _
lParam As Any) As Long
Private Const BM_SETSTYLE As Long = &HF4
Private Const BS_GROUPBOX As Long = &H7&

Rate Frame 'flickering' in Windows XP Goodbye (2(2 Vote))
Frame 'flickering' in Windows XP Goodbye.bas

Frame 'flickering' in Windows XP Goodbye Comments

No comments yet — be the first to post one!

Post a Comment

0/1000 characters