Connecting Tech Pros Worldwide Help | Site Map

Disable control based on group secutiry level in MS Access

 
LinkBack Thread Tools Search this Thread
  #1  
Old November 13th, 2005, 03:03 AM
Joscarfas
Guest
 
Posts: n/a
Default Disable control based on group secutiry level in MS Access

Hello to all,

As you can read the subject of this post, this is exactly what I'm
trying to do. I need to disable some controls in my form base on
secutiry level in MS Access; I've been searching all over for a
solution to this problem but unfortunatelly so far I've been unable to
obtain any good results for this problem.

PS: Is this possible after all?

Thanks

  #2  
Old November 13th, 2005, 03:03 AM
Tom van Stiphout
Guest
 
Posts: n/a
Default Re: Disable control based on group secutiry level in MS Access

On 18 Sep 2004 15:07:24 -0700, fausto.vera@gmail.com (Joscarfas)
wrote:

In the Form_Open event of the form, write:
MyControl.Enabled = (IsUserMemberOfGroup(CurrentUser, "SomeGroup"))

This function could be in some module:
Function IsUserMemberOfGroup(ByVal strUser As String, ByVal strGroup
As String) As Boolean
dim varDummy as Variant
on error resume next
varDummy=DBEngine.Workspaces(0).Users(strUser).Gro ups(strGroup).Name
IsUserMemberOfGroup = (Err.Number=0)
End Function

-Tom.

[color=blue]
>Hello to all,
>
>As you can read the subject of this post, this is exactly what I'm
>trying to do. I need to disable some controls in my form base on
>secutiry level in MS Access; I've been searching all over for a
>solution to this problem but unfortunatelly so far I've been unable to
>obtain any good results for this problem.
>
>PS: Is this possible after all?
>
>Thanks[/color]

  #3  
Old November 13th, 2005, 03:06 AM
Joscarfas
Guest
 
Posts: n/a
Default Re: Disable control based on group secutiry level in MS Access

Tom - thanks for your suggestion; is it possible that you can guide me
on how to do this since I'm not too familiar with any type of coding.
Thanks

Tom van Stiphout <no.spam.tom7744@cox.net> wrote in message news:<i6fpk0158d99uufud0laeo0eq49r1svrf4@4ax.com>. ..[color=blue]
> On 18 Sep 2004 15:07:24 -0700, fausto.vera@gmail.com (Joscarfas)
> wrote:
>
> In the Form_Open event of the form, write:
> MyControl.Enabled = (IsUserMemberOfGroup(CurrentUser, "SomeGroup"))
>
> This function could be in some module:
> Function IsUserMemberOfGroup(ByVal strUser As String, ByVal strGroup
> As String) As Boolean
> dim varDummy as Variant
> on error resume next
> varDummy=DBEngine.Workspaces(0).Users(strUser).Gro ups(strGroup).Name
> IsUserMemberOfGroup = (Err.Number=0)
> End Function
>
> -Tom.
>
>[color=green]
> >Hello to all,
> >
> >As you can read the subject of this post, this is exactly what I'm
> >trying to do. I need to disable some controls in my form base on
> >secutiry level in MS Access; I've been searching all over for a
> >solution to this problem but unfortunatelly so far I've been unable to
> >obtain any good results for this problem.
> >
> >PS: Is this possible after all?
> >
> >Thanks[/color][/color]
 

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Popular Articles

What is Bytes?

We are a network of experts and professionals in IT and software development that help one another with answers to tough questions and share insights. Get the best answers to your questions from over 220,840 network members.