[2 days left] What’s wrong with your cloud strategy? Learn why multicloud solutions matter with Nimble Storage.Register Now

x
?
Solved

How To Find if Excel Selection has any Hidden Rows/Columns

Posted on 2013-05-18
2
Medium Priority
?
321 Views
Last Modified: 2013-05-19
Heyas,

Is their a way in VBA to determine if an excel cell selection has any missing rows or colums in the selection?

Any help would be much appeciated.

Thank you.
0
Comment
Question by:Zack
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 81

Accepted Solution

by:
byundt earned 2000 total points
ID: 39177342
If you don't have more than 8192 non-contiguous areas (a limit removed in Excel 2010 and later) you could use SpecialCells to return the visible cells:
NumberHiddenRows = Selection.Rows.Count - Selection.SpecialCells(xlCellTypeVisible).Rows.Count

Open in new window


If you have Excel 2007 and earlier and might have more than 8192 non-contiguous areas in your selection, then you need to loop through the selection 16000 cells at a time.
0
 

Author Closing Comment

by:Zack
ID: 39179734
Thank you for the info.
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This code takes an Excel list of URL’s and adds a header titled “URL List”. It then searches through all URL’s in column “A”, looking for duplicates. When a duplicate is found, it is moved to the top of the list. The duplicate URL’s are then highlig…
Excel can be a tricky bit of software to get your head around. Whilst you’ll be able to eventually get to grips with the basic understanding of how to get by, there are a few Excel tips that not everybody will even know about let alone know how to d…
Graphs within dashboards are meant to be dynamic, representing data from a period of time that will change each time the dashboard is updated with new data. Rather than update each graph to point to a different set within a static set of data, t…
This Micro Tutorial demonstrates in Microsoft Excel how to consolidate your marketing data by creating an interactive charts using form controls. This creates cool drop-downs for viewers of your chart to choose from.

649 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question