Better do it this way, as it is an extended style: #define GWL_EXSTYLE (-20) SetWindowLong( oWnd:hWnd, GWL_EXSTYLE, WS_EX_CLIENTEDGE ) or SetWindowLong( oWnd:hWnd, GWL_EXSTYLE, nOr( GetWindowLong( oWnd:hWnd, GWL_EXSTYLE ), WS_EX_CLIENTEDGE ) ) to keep the previous extended style too