+ Reply to Thread
Results 1 to 5 of 5

Macro HideEntireRow based on cell Value

  1. #1
    Registered User
    Join Date
    04-23-2009
    Location
    Austin, TX
    MS-Off Ver
    Excel 2007
    Posts
    3

    Macro HideEntireRow based on cell Value

    I need some assistance writing a macro to do the following:

    Upon selecting/activating the designated sheet, perform the following actions in order:
    1. Unhide any previously hidden rows

    2. ScreenUpdate

    3. check value of each cell in range AM1:AM7140, if value is = 1, then hideentirerow = true

    4. ScreenUpdate

    5. check value of each cell in range AL1:AL7140, if value is < 1, then hideentirerow = true

    6. ScreenUpdate

    Any assistance that you can provide would be greatly appreciated.

    Thanks,

  2. #2
    Forum Expert royUK's Avatar
    Join Date
    11-18-2003
    Location
    Derbyshire,UK
    MS-Off Ver
    Xp; 2007; 2010
    Posts
    26,200

    Re: Macro HideEntireRow based on cell Value

    Why not use AotoFilter. You can automate AotoFilter with a macro if you want
    Hope that helps.

    RoyUK
    --------
    For Excel Tips & Solutions, free examples and tutorials why not check out my web site

    Free DataBaseForm example

  3. #3
    Registered User
    Join Date
    04-23-2009
    Location
    Austin, TX
    MS-Off Ver
    Excel 2007
    Posts
    3

    Re: Macro HideEntireRow based on cell Value

    thanks, i guess i was over complicating things.

    how can i have the sheet automatically reapply the filter everytime the sheet is selected?

    thanks again,

  4. #4
    Forum Expert royUK's Avatar
    Join Date
    11-18-2003
    Location
    Derbyshire,UK
    MS-Off Ver
    Xp; 2007; 2010
    Posts
    26,200

    Re: Macro HideEntireRow based on cell Value

    To best describe or illustrate your problem you would be better off attaching a dummy workbook, the workbook should contain the same structure and some dummy data of the same type as the type you have in your real workbook - so, if a cell contains numbers & letters in this format abc-123 then that should be reflected in the dummy workbook.

    If needed supply a before and after sheet in the workbook so the person helping you can see what you are trying to achieve.

    Doing this will ensure you get the result you need!

  5. #5
    Registered User
    Join Date
    04-23-2009
    Location
    Austin, TX
    MS-Off Ver
    Excel 2007
    Posts
    3

    Re: Macro HideEntireRow based on cell Value

    ok, here you go. it's a large file.

    basically, we're using excel to create forms templates for our case managers so that they can pre-print the documents with the correct dates on them.

    what i need is:

    on sheet: progress_notes
    if cell value in column AL is = 0, then hide
    if cell value in column AM is = 1, then hide

    thanks
    Attached Files Attached Files

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1