Menu bars based on users.............
-
Hi i have tried menubars in my form, i got the solution........, But now i need that menubars want to display based on the user rights..., if he dont have rights for some menus that wont display,when he logged on in that time, i tried that probs using some flags...., but i didnt get solution...., anyone plz help me......, i need that codes........, Regards, Magesh
Magesh
-
Hi i have tried menubars in my form, i got the solution........, But now i need that menubars want to display based on the user rights..., if he dont have rights for some menus that wont display,when he logged on in that time, i tried that probs using some flags...., but i didnt get solution...., anyone plz help me......, i need that codes........, Regards, Magesh
Magesh
not work with flags?, can you show me the code?, you systems must check the username, set flags to this users and enabled/unabled menus.
Manuel say: Greetings from Mexico, Cuando salga el sol, no estare aqui... --------------------------------------- Web: http://www.otakuzone-fanzine.com Forum: http://www.otakuzone-fanzine.com/foro
-
Hi i have tried menubars in my form, i got the solution........, But now i need that menubars want to display based on the user rights..., if he dont have rights for some menus that wont display,when he logged on in that time, i tried that probs using some flags...., but i didnt get solution...., anyone plz help me......, i need that codes........, Regards, Magesh
Magesh
Sorry, Are you looking for VB6 or VB.NET solution? Sounds like you should have the access rights setup for a users group and check with IsInRole method of a WindowsPrincipal object. Is that the path you like to take? Jelle
-
Sorry, Are you looking for VB6 or VB.NET solution? Sounds like you should have the access rights setup for a users group and check with IsInRole method of a WindowsPrincipal object. Is that the path you like to take? Jelle
Hi i am using vb.net...., Using javascript i displayed menubars in my form, now i want to dispaly the menubars based on the user rights..., If u know plz send me the code........,
Magesh
-
not work with flags?, can you show me the code?, you systems must check the username, set flags to this users and enabled/unabled menus.
Manuel say: Greetings from Mexico, Cuando salga el sol, no estare aqui... --------------------------------------- Web: http://www.otakuzone-fanzine.com Forum: http://www.otakuzone-fanzine.com/foro
Hi used javascript and displayed menubars in my form.., See each menu have submenus..., i given for each form pageno(its the flag)..., my ques is very critical, take eg like.. two menus are there..., in that two menus have 3,3 submenus.., now one user can access in that first menu 2 forms and second menu 1 form...., another can access in first menu 3 forms and second menu two forms..., now how u can tell...,in that login page these are the forms menus only want to display like......, regards,
Magesh
-
Hi i am using vb.net...., Using javascript i displayed menubars in my form, now i want to dispaly the menubars based on the user rights..., If u know plz send me the code........,
Magesh
So VB.NET it is. I do not understand the rest of your comments. I would build the menu's in full form and not enable the items that an UserGroup can not use or hid the menu item altogether if that is preferred. For doing so: You can decorate you menu creation with;
'Get a WindowsIdentity object for the current user. NameSpace: System.Security.Principal Dim currentIdentity as WindowsIdentity = WindowsIdentity.GetCurrent() 'The WindowsPrincipal class can give access to the user's group memberships Dim currentPrincipal as WindowsPrincipal = New WindowsPrincipal(currentIdentity)
And use the following to test if menu items should be "not enabled" or "hidden".if currentPrincipal.IsInRole("DOMAIN/Group Name") Then ' substitute DOMAIN and Group Name 'Do your menu item setting End if
Clean up you objects. IsInRole can to with a Try block. I hope it is something like this you are after. Else I possibly can do with some code. Jelle -
Hi i am using vb.net...., Using javascript i displayed menubars in my form, now i want to dispaly the menubars based on the user rights..., If u know plz send me the code........,
Magesh
asp.net not work with javascript (directly), maybe you should enabled/unabled these menus with javascript and not with asp.net, this menus will be layers, with javascript activate this layers, the flags must take yours values from asp by strings or cookies and then activate the layers.
Manuel say: Greetings from Mexico, Cuando salga el sol, no estare aqui... --------------------------------------- Web: http://www.otakuzone-fanzine.com Forum: http://www.otakuzone-fanzine.com/foro