Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.newusers
external usenet poster
 
Posts: 7
Default unhidden row

May I know how to number unhidden rows only
  #2   Report Post  
Posted to microsoft.public.excel.newusers
external usenet poster
 
Posts: 10,124
Default unhidden row

I never felt a need to do this but this should do it.

Sub numbervisiblerows()
mc = 2'column number to check 2 is column B
For i = 1 To Cells(Rows.Count, mc).End(xlUp).Row
If Rows(i).Hidden = False Then Cells(i, mc -1) = j
j = j + 1
Next i
End Sub
--
Don Guillett
Microsoft MVP Excel
SalesAid Software

"Nahc" wrote in message
...
May I know how to number unhidden rows only


  #3   Report Post  
Posted to microsoft.public.excel.newusers
external usenet poster
 
Posts: 7
Default unhidden row

sorry sir, is there a simpler explanation ?

"Don Guillett" wrote:

I never felt a need to do this but this should do it.

Sub numbervisiblerows()
mc = 2'column number to check 2 is column B
For i = 1 To Cells(Rows.Count, mc).End(xlUp).Row
If Rows(i).Hidden = False Then Cells(i, mc -1) = j
j = j + 1
Next i
End Sub
--
Don Guillett
Microsoft MVP Excel
SalesAid Software

"Nahc" wrote in message
...
May I know how to number unhidden rows only



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
unhidden row only Nahc Excel Discussion (Misc queries) 3 February 22nd 08 02:36 PM
Copying only unhidden rows Cathy Excel Discussion (Misc queries) 2 October 17th 07 03:36 PM
Print only unhidden rows fstone09 Excel Worksheet Functions 11 May 23rd 07 01:18 PM
sumif only for unhidden rows Bob Phillips Excel Worksheet Functions 5 December 11th 05 08:43 AM
Protecting a worksheet so it cant be unhidden ynissel Excel Discussion (Misc queries) 2 June 10th 05 08:59 PM


All times are GMT +1. The time now is 07:08 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"