|
-
Aug 30th, 2000, 05:44 AM
#1
Thread Starter
New Member
Hi
Anyone know how to get the MDI form to cover the startmenu? I know how to get a normal form to cover it, but I can't get the MDI form to cover it... and is there a way to get rid of the border aswell?
thanks
-
Aug 30th, 2000, 08:24 AM
#2
_______
<?>
Code:
'bas module code
Option Explicit
'this will give you full screen without
'have to hide taskbar
Public Declare Function SetWindowPos Lib "user32" _
(ByVal hwnd As Long, ByVal hWndInsertAfter As Long, _
ByVal x As Long, ByVal y As Long, ByVal cx As Long, _
ByVal cy As Long, ByVal wFlags As Long) As Long
Public Declare Function GetSystemMetrics Lib "user32" _
(ByVal nIndex As Long) As Long
Public Const SM_CXSCREEN = 0
Public Const SM_CYSCREEN = 1
Public Const HWND_TOP = 0
Public Const SWP_SHOWWINDOW = &H40
'MDIForm code
Option Explicit
Private Sub MDIForm_Activate()
Dim cx As Long
Dim cy As Long
Dim RetVal As Long
' Determine if screen is already maximized.
If Me.WindowState = vbMaximized Then
' Set window to normal size
Me.WindowState = vbNormal
End If ' Get full screen width.
cx = GetSystemMetrics(SM_CXSCREEN) ' Get full screen height.
cy = GetSystemMetrics(SM_CYSCREEN)
' Call API to set new size of window.
RetVal = SetWindowPos(Me.hwnd, HWND_TOP, 0, 0, cx, cy, SWP_SHOWWINDOW)
End Sub
'as for the border...midi forms have no border propery
'so you are stuck with it
"A myth is not the succession of individual images,
but an integerated meaningful entity,
reflecting a distinct aspect of the real world."
___ Adolf Jensen
-
Aug 30th, 2000, 09:59 PM
#3
Thread Starter
New Member
Thank you
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|