Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11
Default How do you list all the workbooks you have opened and the sheets in each workbook?

How do you display a list of open workbooks and each sheet name in that
workbook??

Thanks

wendy


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,272
Default How do you list all the workbooks you have opened and the sheets in each workbook?

Wendy,

Try this

Dim i As Long
Dim wb As Workbook
Dim ws As Worksheet

i = 1
For Each wb In Workbooks
ActiveSheet.Cells(i, 1) = wb.Name
i = i + 1
For Each ws In wb.Worksheets
ActiveSheet.Cells(i, 2) = ws.Name
i = i + 1
Next ws
Next wb


--

HTH

Bob Phillips
... looking out across Poole Harbour to the Purbecks
(remove nothere from the email address if mailing direct)

"Wendy" wrote in message
...
How do you display a list of open workbooks and each sheet name in that
workbook??

Thanks

wendy




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
History of Workbooks opened derek Excel Worksheet Functions 1 May 20th 09 05:55 PM
list sheets in workbook John Excel Discussion (Misc queries) 3 March 11th 09 03:58 AM
Merging workbooks into different sheets in a different workbook Nico Excel Discussion (Misc queries) 0 November 6th 07 07:49 AM
List all sheets present in Workbook Jeff Excel Worksheet Functions 6 November 9th 06 09:03 PM
list of opened workbooks and selection Valeria[_2_] Excel Programming 3 December 4th 03 09:27 AM


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