Hi All,
I have macro with a userform which extracts some data from a sql database based on the parameters selected in it. i have circulated this macro to my team members now i want a macro code which will check a list which is maintained by me in a form of table in a sql database and allow the user to use that macro only when his name / xp id is updated in that list. For eg :
Sub CheckAccess()
myusername = Environ("username")
If myusername <> mydatabase Then
'now i want a code which should check the existence of his xp user id in my sql database table if it doesn't exist in that table then should show following message.
MsgBox "Not an Authorized User"
End if
End Sub
Thanks a lot your help in advance.
