Hi All,
Please could you assist in a little issue I have
The user click on a batch file on the remote desktop which makes a copy of the DB to the local pc
When the Login from opens, the navigation pane must be hidden as well as the Ribbon.
The system then shows enable contents, not sure how to set the network location to be trusted via VBA and to enable all macros
I can not set the registry as the file are protected by the server protocol
Please could you assist?
also, after they have logged in, the login window is hidden and the Menu Form must open
my issue is, with some users, the menu does not open and the navigation pane is visible
below is my code when DB opens
and on logging is below code
Please could you assist in a little issue I have
The user click on a batch file on the remote desktop which makes a copy of the DB to the local pc
When the Login from opens, the navigation pane must be hidden as well as the Ribbon.
The system then shows enable contents, not sure how to set the network location to be trusted via VBA and to enable all macros
I can not set the registry as the file are protected by the server protocol
Please could you assist?
also, after they have logged in, the login window is hidden and the Menu Form must open
my issue is, with some users, the menu does not open and the navigation pane is visible
below is my code when DB opens
Private Sub Form_Current()
Call DoCmd.NavigateTo("acNavigationCategoryObjectType")
Call DoCmd.RunCommand(acCmdWindowHide)
DoCmd.ShowToolbar "Ribbon", acToolbarNo
DoCmd.SetWarnings 0
DoCmd.SetWarnings False
End Sub
Private Sub Form_Load()
DBEngine.SetOption dbMaxLocksPerFile, 1000000
DBEngine.SetOption dbMaxBufferSize, 500000
DoCmd.Maximize
frmWidth = Me.InsideWidth
frmHeight = Me.InsideHeight
DoCmd.Restore
DoCmd.MoveSize 0, 0, frmWidth, frmHeight
Call DoCmd.NavigateTo("acNavigationCategoryObjectType")
Call DoCmd.RunCommand(acCmdWindowHide)
DoCmd.ShowToolbar "Ribbon", acToolbarYes
DoCmd.SetWarnings (False)
End Sub
and on logging is below code
Private Sub btnLogin_Click()
Dim cboUserName As String
Dim txtPassword As String
Dim rs As Recordset
Call DoCmd.NavigateTo("acNavigationCategoryObjectType")
Call DoCmd.RunCommand(acCmdWindowHide)
DoCmd.ShowToolbar "Ribbon", acToolbarNo
DoCmd.SetWarnings False
strCBOPass = Me.cboUserName.Column(1)
strPassword = Me.txtPassword
If strCBOPass = strPassword Then
DoCmd.SetWarnings 0
DoCmd.OpenQuery "Update Registration Select to No"
DoCmd.OpenQuery "Clear_Registration_File"
DoCmd.OpenQuery "Update_Registration_All"
DoCmd.RunMacro "Update Aircraft SerialNo-Reg"
DoCmd.RunMacro "Update DAW Sheet TBL"
DoCmd.OpenForm "Menu"
DoCmd.OpenForm "ChangePassword"
Else
MsgBox "Login Unsuccessful"
Exit Sub
End If
DoCmd.OpenQuery "Update DAW Data with Workpack no - Signon"
DoCmd.OpenQuery "Update User Log - Log In"
DoCmd.SelectObject acModule, "OpenOutlook", True
Call DoCmd.NavigateTo("acNavigationCategoryObjectType")
Call DoCmd.RunCommand(acCmdWindowHide)
DoCmd.ShowToolbar "Ribbon", acToolbarNo
End Sub