Results 1 to 4 of 4

Thread: SOLVED excel vba - looping though all worksheets

  1. #1

    Thread Starter
    Member
    Join Date
    Jul 2003
    Location
    Los Angeles, CA
    Posts
    49

    SOLVED excel vba - looping though all worksheets

    I need to be able to loop through all the worksheets of a document w/ out knowing the names of the worksheets. Does anyone know how I could go about doing this?

    Thanks,
    Alex
    Last edited by LodBot; Jul 3rd, 2003 at 01:03 PM.

  2. #2
    I don't do your homework! opus's Avatar
    Join Date
    Jun 2000
    Location
    Good Old Europe
    Posts
    3,863
    You get the number of all Worksheets using:
    VB Code:
    1. ActiveWorkbook.Sheets.Count
    And you can call each of those Sheets using
    VB Code:
    1. ActiveWorkbook.Sheets(Number)
    You're welcome to rate this post!
    If your problem is solved, please use the Mark thread as resolved button


    Wait, I'm too old to hurry!

  3. #3

    Thread Starter
    Member
    Join Date
    Jul 2003
    Location
    Los Angeles, CA
    Posts
    49
    works great

    Thanks for the help

  4. #4
    I don't do your homework! opus's Avatar
    Join Date
    Jun 2000
    Location
    Good Old Europe
    Posts
    3,863
    You're welcome, but don't forget to put "solved" in the original topic.
    You're welcome to rate this post!
    If your problem is solved, please use the Mark thread as resolved button


    Wait, I'm too old to hurry!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width