Access Secuirty - What type of access for DLOOKUP? (1 Viewer)

tembenite

Registered User.
Local time
Today, 15:17
Joined
Feb 10, 2005
Messages
38
I have a user I have created. When they open a form, some code is executed.

If IsNull(DLookup("[lastrun]", "_sysinfo", "ID=1")) then
DO STUFF
end if

For some reason I always get an error, "You do not have the necissary permissions to use PATHTOMYDB Object"

The user has Open/execute access to the form in question (which stays open afterwards anyway). They also have read/update/insert access to the table _sysinfo.

If I comment out this code, it skips over it and goes to the next DLOOKUP awhile later, and has the same error. Any ideas?
 

Pat Hartman

Super Moderator
Staff member
Local time
Today, 15:17
Joined
Feb 19, 2002
Messages
43,486
Why does the table name start with an underscore?
Try creating a querydef that queries the table and then reference the querydef in the DLookup().
 

Users who are viewing this thread

Top Bottom