Consulting

Results 1 to 3 of 3

Thread: Solved: Screen / Worksheet Refresh

  1. #1
    VBAX Mentor
    Joined
    Jan 2009
    Posts
    304
    Location

    Solved: Screen / Worksheet Refresh

    I have a worksheet with 7 Active-X Checkboxes on it.

    Once I'm done with the checkboxes I use the VBA below to hide them.

    The checkbox 1-6 are hidden but the last one - checkbox7 does not go hidden.

    Although if after the code runs and I go to Sheet55 and scroll down and then back up then checkbox7 disappears.

    It's like the worksheet or screen needs to be refresh (I'm just guessing).

    Any ideas why?

    Unfortunatelly I will not be able to share this workbook due to it's content, sorry.

    Thanks...

    JimS


    [vba]
    Sheet55.Select
    Sheet55.Unprotect

    ActiveSheet.Shapes("CheckBox1").Visible = False
    ActiveSheet.Shapes("CheckBox2").Visible = False
    ActiveSheet.Shapes("CheckBox3").Visible = False
    ActiveSheet.Shapes("CheckBox4").Visible = False
    ActiveSheet.Shapes("CheckBox5").Visible = False
    ActiveSheet.Shapes("CheckBox6").Visible = False
    ActiveSheet.Shapes("CheckBox7").Visible = False

    Rows("3:12").Select
    Selection.EntireRow.Hidden = True

    Rows("14").Select
    Selection.EntireColumn.Hidden = False

    [/vba]

  2. #2
    VBAX Mentor
    Joined
    Feb 2009
    Posts
    493
    Location
    at any point of your code do you use application.screenupdating = false?
    -----------------------------------------
    The more you learn about something the more you know you have much to learn.

  3. #3
    VBAX Mentor
    Joined
    Jan 2009
    Posts
    304
    Location
    Yes, but cannot see where I didn't enable it right away. I just worked around it by moving to a different sheet.

    Thanks away...

Posting Permissions

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