NeaPa,
Following code in used for disable sub-menu items for specified user. The problem I am having is one of below user is not able see it (Mean disabled the sub-menu items) I want both of them to see sub-menu when they currently on database. Any there is anything wrong with this code which causing one user unable to use sub-menu items.
Prompt help appreciated
Thanks a lot
Following code in used for disable sub-menu items for specified user. The problem I am having is one of below user is not able see it (Mean disabled the sub-menu items) I want both of them to see sub-menu when they currently on database. Any there is anything wrong with this code which causing one user unable to use sub-menu items.
Code:
Dim blnShow As Boolean blnShow = Nz(StrComp(Me.MyName, "aman", vbTextCompare), True) = False With CommandBars("MyMenu").Controls(1) .Controls(1).Enabled = blnShow .Controls(2).Enabled = blnShow .Controls(3).Enabled = blnShow End With blnShow = Nz(StrComp(Me.MyName, "Ram", vbTextCompare), True) = False With CommandBars("MyMenu").Controls(1) .Controls(1).Enabled = blnShow .Controls(2).Enabled = blnShow .Controls(3).Enabled = blnShow End With
Thanks a lot
Comment