I have an Access Db that I open using VBScripts, but everytime I use it the window for Access appears very small and I have to manually maximize it. Is there a way that I can automatically do this with the script that I already use?
Any assistance would be greatly appreciated.
Thanks,
Travis
Code:
Dim lfsobject
Dim dbsLTTFront
On Error Resume Next
Set lfsObject = CreateObject("Scripting.FileSystemObject")
lfsObject.CopyFile "*************************\Bowen Db.mdb", "C:\Program Files\Bowen Db.mdb"
If Err.Number = 0 Then
Set dbsLTTFront = CreateObject("Access.Application")
dbsLTTFront.AutomationSecurity = 1 'msoAutomationSecurityLow
dbsLTTFront.Visible = True
dbsLTTFront.OpenCurrentDatabase "C:\Program Files\Bowen Db.mdb"
dbsLTTFront.userControl=true
Else
'Err number 70, 7866 and -2147023170 sometimes occur with rampant clicking
Msgbox ("The application takes a moment to load, please be patient.")
End If
Any assistance would be greatly appreciated.
Thanks,
Travis