I have one database and the application window and vba screens are not saving as maximized.
I tried several scripts to make it save as maximized but when I close the database and reopen it it is set to restore.
also tried code from the following link
API: Manipulate Access Window
I think that it may be cased by opening it from another database, I am using the following script.
I tried several scripts to make it save as maximized but when I close the database and reopen it it is set to restore.
Code:
Access.RunCommand acCmdAppMaximize
also tried code from the following link
API: Manipulate Access Window
I think that it may be cased by opening it from another database, I am using the following script.
Code:
Dim strInput As String
strInput = "C:\DBase\KLIKSTORES PURCHASING SS NOT LIVE.accdb" 'This references a text box on my form that has a file path
Application.FollowHyperlink strInput, , True 'Setting this to True opens the database in another window
Dim fso
Set fso = CreateObject("Scripting.FileSystemObject")
If fso.FileExists("KLIKSTORES PURCHASING SS NOT LIVE.laccdb") Then
'MsgBox "Access is open!"
Dim OtherDB As Object
sOther = "C:\DBase\KLIKSTORES PURCHASING SS NOT LIVE.accdb"
Set OtherDB = GetObject(sOther)
OtherDB.Forms![ItemFilter]![txtReturnToForm] = "Mainswitch"
Set OtherDB = Nothing
Else
'MsgBox "not open"
End If
Last edited: