If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
Starting Access Maximized
I have created a database with a form that comes up as an
initial menu. Unfortunately, the form isn't maximized inside Access, but is windowed. I have noticed that whenever the database window is maximized, the form will maximize too. How can I default Access to start Maximized? Sorry this may sound simple, but I'm a simple guy. Thanks for any help. |
#2
|
|||
|
|||
Starting Access Maximized
Try setting the form to maximize when it opens.
----- Novice wrote: ----- I have created a database with a form that comes up as an initial menu. Unfortunately, the form isn't maximized inside Access, but is windowed. I have noticed that whenever the database window is maximized, the form will maximize too. How can I default Access to start Maximized? Sorry this may sound simple, but I'm a simple guy. Thanks for any help. |
#3
|
|||
|
|||
Starting Access Maximized
Right click the shortcut to Access, choose Properties, on the Short Cut tab
go to Run and change Normal Window to Maximized. You could also do this in the form's Load event. I just tried the following code from the API Guide distributed by AllAPI.Net and it worked. There may be more here than is necessary, I haven't gone through it to see if any of it can be removed. Option Compare Database Option Explicit Private Const SW_MINIMIZE = 6 Private Const SW_MAXIMIZE = 3 Private Type POINTAPI x As Long y As Long End Type Private Type RECT Left As Long Top As Long Right As Long Bottom As Long End Type Private Type WINDOWPLACEMENT Length As Long flags As Long showCmd As Long ptMinPosition As POINTAPI ptMaxPosition As POINTAPI rcNormalPosition As RECT End Type Private Declare Function ClientToScreen Lib "user32" (ByVal hwnd As Long, lpPoint As POINTAPI) As Long Private Declare Function GetWindowPlacement Lib "user32" (ByVal hwnd As Long, lpwndpl As WINDOWPLACEMENT) As Long Private Declare Function SetWindowPlacement Lib "user32" (ByVal hwnd As Long, lpwndpl As WINDOWPLACEMENT) As Long Dim Rectan As RECT Private Sub Form_Load() 'Tip submitted by pyp99 ) Dim WinEst As WINDOWPLACEMENT Dim Punto As POINTAPI Dim rtn As Long WinEst.Length = Len(WinEst) 'get the current window placement rtn = GetWindowPlacement(Application.hWndAccessApp, WinEst) Rectan = WinEst.rcNormalPosition 'set the new min/max positions 'these 2 lines probably aren't needed just to maximize the Access window Punto.x = 100 Punto.y = 100 'initialize the structure WinEst.Length = Len(WinEst) WinEst.showCmd = SW_MAXIMIZE WinEst.ptMinPosition = Punto WinEst.ptMaxPosition = Punto WinEst.rcNormalPosition = Rectan 'set the new window placement (minimized) rtn = SetWindowPlacement(Application.hWndAccessApp, WinEst) 'Now maximize the form DoCmd.Maximize End Sub -- Wayne Morgan MS Access MVP "Novice" wrote in message ... I have created a database with a form that comes up as an initial menu. Unfortunately, the form isn't maximized inside Access, but is windowed. I have noticed that whenever the database window is maximized, the form will maximize too. How can I default Access to start Maximized? Sorry this may sound simple, but I'm a simple guy. Thanks for any help. |
#4
|
|||
|
|||
Starting Access Maximized
To open up the application in maximized mode
in a macro Action: RunCommand Command: AppMaximize In code DoCmd.RunCommand acCmdAppMaximize Jim -----Original Message----- I have created a database with a form that comes up as an initial menu. Unfortunately, the form isn't maximized inside Access, but is windowed. I have noticed that whenever the database window is maximized, the form will maximize too. How can I default Access to start Maximized? Sorry this may sound simple, but I'm a simple guy. Thanks for any help. . |
#5
|
|||
|
|||
Starting Access Maximized
This was my original question. How do I get it to default
to Maximized? -----Original Message----- Try setting the form to maximize when it opens. ----- Novice wrote: ----- I have created a database with a form that comes up as an initial menu. Unfortunately, the form isn't maximized inside Access, but is windowed. I have noticed that whenever the database window is maximized, the form will maximize too. How can I default Access to start Maximized? Sorry this may sound simple, but I'm a simple guy. Thanks for any help. . |
#6
|
|||
|
|||
Starting Access Maximized
wrote in message
... This was my original question. How do I get it to default to Maximized? In the OpenEvent of your form have code... DoCmd.Maximize. This will not maximize Access on your desktop, but will maximize the form within the Access window. -- I don't check the Email account attached to this message. Send instead to... RBrandt at Hunter dot com |
Thread Tools | |
Display Modes | |
|
|