+ Reply to Thread
Results 1 to 12 of 12

IsHidden

  1. #1
    Registered User
    Join Date
    03-04-2008
    Posts
    60

    IsHidden

    I'm trying to create a custom function that will return if a cell is hidden or not. I have it working with just a single cell being called
    Please Login or Register  to view this content.
    Please Login or Register  to view this content.
    But I need to get the function to also work with a range like
    Please Login or Register  to view this content.
    Basically the same way that the Row() function works

  2. #2
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2010, 2019
    Posts
    40,689

    Re: IsHidden

    What is it supposed to return when you pass a range and some cells are hidden and some not?
    Entia non sunt multiplicanda sine necessitate

  3. #3
    Registered User
    Join Date
    03-04-2008
    Posts
    60

    Re: IsHidden

    An array? of true/false values. If I call Row(A3) i get 3, if i call Row(A3:A4) i get 3,4 being return

  4. #4
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2010, 2019
    Posts
    40,689

    Re: IsHidden

    That's easy enough to do, but what's the advantage of returning an array versus just dragging the formula =IsHidden(A3) right and/or down?

    The disadvantage of an array formula is that you can't insert rows or columns interior to the array. Not a big thing, but here there's no reason for the inconvenience.
    Last edited by shg; 02-23-2009 at 06:39 PM.

  5. #5
    Registered User
    Join Date
    03-04-2008
    Posts
    60

    Re: IsHidden

    So I can use this function with Conditional Formatting. I want to automate alternative rows being highlighted and currently any hidden rows will mess this up using the =IF(MOD(ROW(), 2) = 1) formula, instead id need to do, =IF(MOD(COUNTIF(IsHidden($A2:D2), "= 1"), 2) = 1)

    And I'd like it to still work with a single cell just like row() does

  6. #6
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2010, 2019
    Posts
    40,689

    Re: IsHidden

    Alas, you can't use array formulas in conditional formatting.

    You might use this:

    Please Login or Register  to view this content.
    Then in A1, CF Formula is =MOD(nVis(A$1:A1), 2)=1 and copy formatting down.

  7. #7
    Registered User
    Join Date
    03-04-2008
    Posts
    60

    Re: IsHidden

    What do you mean you can't use array formulas in Condition Formatting? row($A$1:$A1) works just fine

  8. #8
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2010, 2019
    Posts
    40,689

    Re: IsHidden

    Sorry, brain cramp. Go for it.

  9. #9
    Registered User
    Join Date
    03-04-2008
    Posts
    60

    Re: IsHidden

    I still don't know how to actually implement the function =\

  10. #10
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2010, 2019
    Posts
    40,689

    Re: IsHidden

    Did you try the one I provided?

  11. #11
    Registered User
    Join Date
    03-04-2008
    Posts
    60

    Re: IsHidden

    Ah, I just saw it as a diff function haha Ok, so I tried it and.. technically it works, but its prohibitively too slow to even use. So, you were right and wrong about them not working

  12. #12
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2010, 2019
    Posts
    40,689

    Re: IsHidden

    Here's an array verson of your function. I'm not sure what problem it solves.
    Please Login or Register  to view this content.
    Last edited by shg; 02-24-2009 at 06:26 PM.

+ 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