I need CIR.vendor to be distinct. here is the code that does not use distinct. I can't just stick dinstinct row or distinct in there because there is a different index number for each row. This is for a listbox on a form.
SELECT CIR.Vendor, CIR.index
from CIR
ORDER BY CIR.Vendor;
OK, this thing is still not working. This is where the code stands right now...
For Each ctl In Me.Controls
If Len(ctl.Tag & "") <> 0 Then 'check for ABCD user role
ctl.Enabled = strLevel <= ctl.Tag 'Enable based on user role
If Right(ctl.Tag, 1) = "N" And Left(ctl.Tag, 1) >= "B" And Not...
First I will answer your questions. By some fields in the form I mean there are a few fields, that should allow C level users to input the initial data, but not change it. Admins sould bbe the only one that can change it. This does not apply to all of the field I am restricting so your left and...
I have one more twist that has been added.
For some fields in the form, that are available for A,B,and C levels, I need to check to see if the field has a value, if so, lock it except for Admins (A).
I have poked around with this code today, but just haven't put it together correctly. I'm...
I know we jumped to the GetRole function, but I was actually learning and understanding you based on the baby steps you were doing (thanks). You left off with my security levels being A,B,C and D. This is correct.
I realize the on open code will use the getrole function to return the users...
I know this is something I SHOULD be able to fgure out, but the previous code is blowing chunks @ ([Security Level] FROM
It says compile error: List separator or ) expected.
Thanks, GoAutoWay
Well, Ace, yes, that would make sense! It's the only missing link here...
Duane, that is acceptable. It is exactly what I'm trying to accomplish. I need the Getrole() function though...
Thanks,
Toby
Yes, The table name is employee
The fields are: UID, First Name, Middle Name, Last Name and Security Level. Security levels are A,B,C and D.
There are many fields in the form that will be locked based on UID and Security Level, at least that is the goal.
I do know which fields should be at...
Yes, I used the code listed in the previous threads link to grab the login. I also have a table called employees with the logins and security from A Admin B Manager C User D Read only. Obviously I'm willing to change the table around if I can just get this last part going. I know I'm so close...
thread702-1609388
I'm trying to lock certain fields in a form based on user login and a table created withh user and security levels.
I think the above thread would work but I am new to VB and Access and I do not have the GetRole() function. I am assuming this is user defined?? Thanks,
Go
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.