|
Const GWL_STYLE = (-16)
Const WS_CAPTION = &HC00000
Const Ws_OnlyClose = &H30000
Const WS_SYSMENU = &H80000
Declare Function GetWindowLongA Lib "user32" (ByVal hWnd As Long, ByVal nIndex As Long) As Long
Declare Function SetWindowLongA Lib "user32" (ByVal hWnd As Long, ByVal nIndex As Long, ByVal dwNewLong As Long) As Long
Declare Function DrawMenuBar Lib "user32" (ByVal hWnd As Long) As Long
Function SetFlatten()
Dim hWnd As Long
Dim Ls As Long
hWnd = Application.hWndAccessApp
Ls = GetWindowLongA(hWnd, GWL_STYLE)
SetWindowLongA hWnd, GWL_STYLE, Ls And Not Ws_OnlyClose
'SetWindowLongA hWnd, GWL_STYLE, Ls Or Ws_OnlyClose
DrawMenuBar hWnd
End Function |
|