Jonathan Kok
Registered User.
- Local time
- Yesterday, 20:38
- Joined
- Jan 27, 2000
- Messages
- 116
Allright, so I've got a Purchase Order database that I created a number of years ago. It's been working fine, up until last week. When a user other than myself attempts to open the 'receive po' form from their workstation, I can see in the status bar that it calculates, then filters the form, but nothing actually appears, and I'm back to the switchboard. The form is designed to filter based on a user's security level (stored in a table) using the 'applyfilter' function. The username is pulled from their network userid using a function that runs from the switchboard, and matched to a userid in a table. Here's the code:
Like I said, this worked until last week. Suddenly, only *I* have access to this particular form. I can log into any workstation on the network, and it works. No-one else can. All the machines run Windows XP and Office 2003, at various service pack levels, with or without .NET installed. Whether it's WinXP SP1 and the core Office, no .NET, or WinXP SP2 and Office SP1 with .NET 1.1, the same thing happens. I am an administrator on the domain, and all the users are administrators of the local machine(s).
I have other forms performing the exact same operation, word for word, and there's no problems with them. Just this one. I've commented out the close function, and the same thing happens, so it's not that. I've dropped my DB security level to match the other users, and I can still open it without a problem. The only way other users can open it is if I comment out the filter function. Which is a potential solution, but the point of the filtering is so that people can't mess up other people's PO's.
The only thing I can think of is that it has something to do with the fact I'm an admin on the domain, but that shouldn't make a difference whatsoever. Yet it does. Which makes no sense.
Any ideas?
Code:
'When form is first opened, adjusts it to suit user
'Last update 10/07/00
Private Sub Form_Open(Cancel As Integer)
On Error GoTo Err_Form_Open
Dim UsersName
UsersName = GetCurrentUserName()
If Forms!Switchboard!secLevel = 5 Then
ElseIf Forms![Switchboard]![secLevel] = 4 Then
DoCmd.ApplyFilter , "OrdSecure = False Or OrdEnteredBy = '" & UsersName & "'"
ElseIf Forms![Switchboard]![secLevel] = 3 Then
DoCmd.ApplyFilter , "OrdEnteredBy = '" & UsersName & "'"
Else
DoCmd.Close
End If
DoCmd.Maximize
Exit_Form_Open:
Exit Sub
Err_Form_Open:
MsgBox Err.Description
Resume Exit_Form_Open
End Sub
Like I said, this worked until last week. Suddenly, only *I* have access to this particular form. I can log into any workstation on the network, and it works. No-one else can. All the machines run Windows XP and Office 2003, at various service pack levels, with or without .NET installed. Whether it's WinXP SP1 and the core Office, no .NET, or WinXP SP2 and Office SP1 with .NET 1.1, the same thing happens. I am an administrator on the domain, and all the users are administrators of the local machine(s).
I have other forms performing the exact same operation, word for word, and there's no problems with them. Just this one. I've commented out the close function, and the same thing happens, so it's not that. I've dropped my DB security level to match the other users, and I can still open it without a problem. The only way other users can open it is if I comment out the filter function. Which is a potential solution, but the point of the filtering is so that people can't mess up other people's PO's.
The only thing I can think of is that it has something to do with the fact I'm an admin on the domain, but that shouldn't make a difference whatsoever. Yet it does. Which makes no sense.
Any ideas?