Consulting

Page 2 of 2 FirstFirst 1 2
Results 21 to 26 of 26

Thread: Ribbon - toggle button problems

  1. #21
    Try this in the workbook that you sent me:
    1. open workbook
    2. go to sheet 1, press lock
    3. go to sheet 2, press lock
    4. go to sheet 3, press lock
    5. just switch between the sheets, go from sheet 1 to sheet 2 to sheet 3.
    The buttons state does not update ( one or more sheets have the two buttons at state false )

  2. #22
    VBAX Wizard
    Joined
    Apr 2007
    Posts
    6,391
    Location
    try this

    i cleand up the logic and code a little more

    if you make a manual protection change, i don't know of any way to update the ribbon, but if you switch out and back in it should update
    Attached Files Attached Files
    Paul

    ------------------------------------------------------------------------------------------------------------------------
    1. Use [CODE] ....[/CODE ] Tags for readability
    [CODE]PasteYourCodeHere[/CODE ] -- (or paste your code, select it, click [#] button)
    2. Upload an example
    Go Advanced / Attachments - Manage Attachments / Add Files / Select Files / Select the file(s)
    (multiple files can be selected while holding Ctrl key) / Upload Files / Done
    3. Mark the thread as [Solved] when you have an answer
    Thread Tools (on the top right corner, above the first message)
    4. Read the Forum FAQ, especially the part about cross-posting in other forums
    http://www.vbaexpress.com/forum/faq...._new_faq_item3

  3. #23
    Hello
    Thanks a lot, now it works perfectly.
    I commented this line: Err.Clear '<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
    Because the Err.Clear removed the error number witch i used to allow specific people to lock or unlock the sheets.
    And with the line active the msgbox's did not appear if user was not found in the first sheet.
    But now it works perfectly, thank you very much

  4. #24
    VBAX Wizard
    Joined
    Apr 2007
    Posts
    6,391
    Location
    Try this version

    I added a Workbook_Open and cleanup up some other code

    I "think' it fixes those two issues
    Attached Files Attached Files
    Paul

    ------------------------------------------------------------------------------------------------------------------------
    1. Use [CODE] ....[/CODE ] Tags for readability
    [CODE]PasteYourCodeHere[/CODE ] -- (or paste your code, select it, click [#] button)
    2. Upload an example
    Go Advanced / Attachments - Manage Attachments / Add Files / Select Files / Select the file(s)
    (multiple files can be selected while holding Ctrl key) / Upload Files / Done
    3. Mark the thread as [Solved] when you have an answer
    Thread Tools (on the top right corner, above the first message)
    4. Read the Forum FAQ, especially the part about cross-posting in other forums
    http://www.vbaexpress.com/forum/faq...._new_faq_item3

  5. #25
    Hello, works perfectly, thank you.

  6. #26
    VBAX Wizard
    Joined
    Apr 2007
    Posts
    6,391
    Location
    Quote Originally Posted by Rolly_Sefu View Post
    Hello
    I commented this line: Err.Clear '<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
    Yes, I used that to bypass the password checking since I was only interested in getting the buttons to work the way you wanted
    Paul

    ------------------------------------------------------------------------------------------------------------------------
    1. Use [CODE] ....[/CODE ] Tags for readability
    [CODE]PasteYourCodeHere[/CODE ] -- (or paste your code, select it, click [#] button)
    2. Upload an example
    Go Advanced / Attachments - Manage Attachments / Add Files / Select Files / Select the file(s)
    (multiple files can be selected while holding Ctrl key) / Upload Files / Done
    3. Mark the thread as [Solved] when you have an answer
    Thread Tools (on the top right corner, above the first message)
    4. Read the Forum FAQ, especially the part about cross-posting in other forums
    http://www.vbaexpress.com/forum/faq...._new_faq_item3

Posting Permissions

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