Results 1 to 9 of 9
  1. #1
    Gold Lounger
    Join Date
    Jan 2004
    Location
    Italy
    Posts
    3,245
    Thanks
    0
    Thanked 0 Times in 0 Posts

    PERMISSION on menu and toolbar... (6.0)

    Have a mdi firm with toolbar1 and 4 Menu.
    Now i have a var named "PERMISSION" actually is filled with "Yes"
    How to permit to navigate in toolbar1 and in the various menu of mdi form only if this var is filled with "Yes"...
    Example the var is filled with "No" disable option in menu or disable to click on the button on statusbar1

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: PERMISSION on menu and toolbar... (6.0)

    Do you have code that changes Permission from Yes to No or from No to Yes?

    If so, you can add code there that sets the Enabled property of the menu items and toolbar buttons.

  3. #3
    Gold Lounger
    Join Date
    Jan 2004
    Location
    Italy
    Posts
    3,245
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: PERMISSION on menu and toolbar... (6.0)

    MDIForm1.mnutools.Enabled = False
    I have this part of code, but disable entire manu and items...
    I want to disable only the item TOOL in this menu and maintain active other???!!!

    Assume have in menu:
    mntools
    TOOL
    USER

  4. #4
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: PERMISSION on menu and toolbar... (6.0)

    The Tool item has a name too. Let's say it is named mnuMyTool (not mnuTools!). You can then use

    MDIForm1.mnuMyTool.Enabled = False

  5. #5
    Gold Lounger
    Join Date
    Jan 2004
    Location
    Italy
    Posts
    3,245
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: PERMISSION on menu and toolbar... (6.0)

    Attached image with menu...
    in effect i want to disable the item UTENTI from menu TOOL...

  6. #6
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: PERMISSION on menu and toolbar... (6.0)

    Click on

    ...&UTENTI

    What is the name in the Name box? That's the one you should use.

  7. #7
    Gold Lounger
    Join Date
    Jan 2004
    Location
    Italy
    Posts
    3,245
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: PERMISSION on menu and toolbar... (6.0)

    the name is UTENTI....

  8. #8
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: PERMISSION on menu and toolbar... (6.0)

    So have you tried using that?

  9. #9
    Gold Lounger
    Join Date
    Jan 2004
    Location
    Italy
    Posts
    3,245
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: PERMISSION on menu and toolbar... (6.0)

    now work!
    TKS AS USUAL!!!
    I have understand is necessary to navigate in menu_name>item_name>....ecc
    Instead is direct the command...GOOD!
    reSolved with:
    MDIForm1.UTENTI.Enabled = False

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •