Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 66
Default Looping through Worksheets

I'm looking for the syntax for a procedure that would loop through all
worksheets in the active workbook, list the name of the worksheet and the
contents of cell A3 for each worksheet.

Can someone help? Thanks!
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default Looping through Worksheets

for each sh in Activeworkbook.Worksheets
With thisworkbook.Worksheets(1).Cells(i,1)
.Value = sh.name
.offset(0,1).value = sh.Range("A3").Value
end with
Next

--
Regards,
Tom Ogilvy
"Kirk P." wrote in message
...
I'm looking for the syntax for a procedure that would loop through all
worksheets in the active workbook, list the name of the worksheet and the
contents of cell A3 for each worksheet.

Can someone help? Thanks!



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
looping through worksheets from addin Paul Robinson Excel Programming 0 October 9th 03 05:12 PM
looping through worksheets from addin Cliff Myers Excel Programming 0 October 9th 03 06:45 AM
Looping Through Worksheets In A Workbook Steve[_27_] Excel Programming 3 August 5th 03 03:40 PM
looping through worksheets Alex ekster Excel Programming 1 July 21st 03 03:16 AM
looping through worksheets alex Excel Programming 0 July 20th 03 06:43 PM


All times are GMT +1. The time now is 08:18 PM.

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

About Us

"It's about Microsoft Excel"