#1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 29
Default Hide Blank Rows

I don't know how to use macros, (I'm assuming I would need one), but does
anyone know of one I could copy/paste into my spreadsheet that will hide
blank rows within a specific range?
--
Thanks for your help!
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 8,520
Default Hide Blank Rows

Set the Security level to low/medium in (Tools|Macro|Security). 'Launch VBE
using short-key Alt+F11. Insert a module and paste the below code. Save. Get
back to Workbook. Tools|Macro|Run the macro()

Change the range as required

Sub RemoveBlankRows()
Dim varRange As Range
Dim lngRow As Long
Set varRange = Range("A1:Z10")

For lngRow = varRange.Rows.Count To varRange.Row Step -1
If WorksheetFunction.CountBlank(Rows(lngRow)) = Columns.Count Then
Rows(lngRow).Delete
End If
Next
End Sub

--
If this post helps click Yes
---------------
Jacob Skaria


"TamIam" wrote:

I don't know how to use macros, (I'm assuming I would need one), but does
anyone know of one I could copy/paste into my spreadsheet that will hide
blank rows within a specific range?
--
Thanks for your help!

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 140
Default Hide Blank Rows

To do this manually, select the entire rows you want to hide by clicking on
the row IDs(1,2,3...) while holding the Ctrl key. Then when all selection
is complete, right click on one of the selected row IDs and choose Hide.

To make a macro to do the same thing, access the macro recorder and start a
macro recording then repeat the same thing from above. Then turn of the
recorder. You can then view, edit, run or delete the macro you recorded.


Dennis

"TamIam" wrote in message
...
I don't know how to use macros, (I'm assuming I would need one), but does
anyone know of one I could copy/paste into my spreadsheet that will hide
blank rows within a specific range?
--
Thanks for your help!


  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 22,906
Default Hide Blank Rows

You don't need a macro.

Select a column within the range and F5SpecialBlanksOK

FormatRowHide.


Gord Dibben MS Excel MVP

On Wed, 6 May 2009 08:43:00 -0700, TamIam
wrote:

I don't know how to use macros, (I'm assuming I would need one), but does
anyone know of one I could copy/paste into my spreadsheet that will hide
blank rows within a specific range?


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Auto Hide Blank Rows Gord Dibben Excel Discussion (Misc queries) 0 February 25th 09 09:52 PM
Hide rows of cells that are blank dford Excel Discussion (Misc queries) 9 February 5th 07 12:35 AM
Hide Blank Rows dee Excel Worksheet Functions 2 May 17th 06 11:30 PM
Formula to hide blank rows Ladyra Excel Worksheet Functions 4 February 25th 05 07:55 PM
remove or hide blank rows Erik Beijlen via OfficeKB.com Excel Discussion (Misc queries) 1 February 1st 05 02:17 PM


All times are GMT +1. The time now is 11:22 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"