Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
disable maximizebox in Excel Title bar
i want to disable the maximizebox of top,right of Excel application title bar. how can i? *** Sent via Developersdex http://www.developersdex.com *** |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
disable maximizebox in Excel Title bar
"x taol" schreef in bericht ... i want to disable the maximizebox of top,right of Excel application title bar. how can i? *** Sent via Developersdex http://www.developersdex.com *** Use the windows API: Private Declare Function FindWindow Lib "user32" Alias "FindWindowA" _ (ByVal lpClassName As String, ByVal lpWindowName As String) As Long Private Declare Function GetWindowLong Lib "user32" Alias "GetWindowLongA" _ (ByVal hWnd As Long, ByVal nIndex As Long) As Long Private Declare Function SetWindowLong Lib "user32" Alias "SetWindowLongA" _ (ByVal hWnd As Long, ByVal nIndex As Long, ByVal dwNewLong As Long) As Long Public Sub DisableMaximizeButton() Dim hWnd As Long Dim hWndStyle As Long hWnd = FindWindow("XLMAIN", Application.Caption) hWndStyle = GetWindowLong(hWnd, -16) hWndStyle = hWndStyle And Not &H10000 SetWindowLong hWnd, -16, hWndStyle End Sub |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
disable maximizebox in Excel Title bar
Thank you very much moon.... but the big problem occured.
After the excel minimize, do the excel up again. and then the excel enter down windows taskbar. oooooo. please.... *** Sent via Developersdex http://www.developersdex.com *** |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
disable maximizebox in Excel Title bar
Thank you very much moon.... but the big problem occured.
After the excel minimize, do the excel up again. and then the excel enter down windows taskbar. oooooo. please.... *** Sent via Developersdex http://www.developersdex.com *** |
#5
Posted to microsoft.public.excel.programming
|
|||
|
|||
disable maximizebox in Excel Title bar
"x taol" schreef in bericht ... Thank you very much moon.... but the big problem occured. After the excel minimize, do the excel up again. and then the excel enter down windows taskbar. oooooo. please.... *** Sent via Developersdex http://www.developersdex.com *** I don't have that problem here, here it works just fine. But you can switch back to normal, using: hWndStyle = hWndStyle Or &H10000 The only thing is that I first have to move my mouse over the titlebar before the MaximizeBox appears or disappears, even after a setfocus. |
#6
Posted to microsoft.public.excel.programming
|
|||
|
|||
disable maximizebox in Excel Title bar
no good. it doesn't work. i want to work well. my wanting is that the maximizebox disable and minimize and restore(up) again and then the excel window be to appear normaly. abnormaly, after minimize the excel window, the window enter down windows taskbar, like full screen. *** Sent via Developersdex http://www.developersdex.com *** |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Excel Title bar | Excel Worksheet Functions | |||
Named range=Column title,comumn title in cellB6 use B6in equation | Excel Discussion (Misc queries) | |||
Show full path title in title bar? | New Users to Excel | |||
Pasting Objects into Chart title and Axis title | Charts and Charting in Excel | |||
Excel add-in set title? | Excel Programming |