I have a database that is used only in the fall for a month or so. It was working last fall without issue, but in the last year, an upgrade to Access 2007 seems to have adjusted some functionality.
Users log in using a UserID such as "Administration", "Conference", "Programs" etc. In the data entry form, the record source should (used to last year) change based on the userID. So, if someone is logged in as Adminstration, the record source will be qryChartOfAccounts-Adminstration. If they are logged in as Conference, the record source will be qryChartOfAccounts-Conference.
What I'm seeing now is that the record source never changes from qryChartOfAccounts-Adminstration. When the Conference user is logged in, he cannot open the data entry form because the record source is qryChartOfAccounts-Administration and he doesn't have permission for that query. "Record(s) cannot be read; no permission on qryChartOfAccounts-Administration."
Here's what I have on open for the data entry form.
Private Sub Form_Open(Cancel As Integer)
Dim strRecordSource As String
strRecordSource = "qryChartOfAccounts-" & CurrentUser()
MsgBox "The record source is " & strRecordSource
Form_frmBudgetEntry.RecordSource = strRecordSource
Me.Requery
End Sub
Anna Jaeger
iMIS Database Support
Users log in using a UserID such as "Administration", "Conference", "Programs" etc. In the data entry form, the record source should (used to last year) change based on the userID. So, if someone is logged in as Adminstration, the record source will be qryChartOfAccounts-Adminstration. If they are logged in as Conference, the record source will be qryChartOfAccounts-Conference.
What I'm seeing now is that the record source never changes from qryChartOfAccounts-Adminstration. When the Conference user is logged in, he cannot open the data entry form because the record source is qryChartOfAccounts-Administration and he doesn't have permission for that query. "Record(s) cannot be read; no permission on qryChartOfAccounts-Administration."
Here's what I have on open for the data entry form.
Private Sub Form_Open(Cancel As Integer)
Dim strRecordSource As String
strRecordSource = "qryChartOfAccounts-" & CurrentUser()
MsgBox "The record source is " & strRecordSource
Form_frmBudgetEntry.RecordSource = strRecordSource
Me.Requery
End Sub
Anna Jaeger
iMIS Database Support