Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6
Default set worksheet name to a variable ...

I must be out of practice because this has got to be very simple and I
just can't figure it out... or it is because I do not have access to my
books ... but, how do you do:

dim sheetName as Worksheet
sheetName = ActiveWorksheet.Name

If sheetName = name_of_first_sheet THEN
do a bunch of stuff
elseif
sheetName = Name_of_second_sheet THEN
do a bunch of other stuff
endif

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6
Default set worksheet name to a variable ...

Nevermind .. I found the answer ... !DOH!

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
Link variable data from one worksheet to another worksheet? T MAT New Users to Excel 3 November 27th 07 06:46 AM
Variable worksheet name (tab) linked to cell in same worksheet azbob Excel Worksheet Functions 6 January 9th 07 06:27 PM
Looking up a variable in one worksheet and copying information from another column to another worksheet?? Brad Torken Excel Discussion (Misc queries) 2 December 10th 06 06:02 AM
Variable VBA Worksheet Name Dave[_61_] Excel Programming 2 November 18th 05 12:57 PM
Assigning worksheet to worksheet variable PO Excel Programming 3 February 10th 04 02:22 PM


All times are GMT +1. The time now is 09:10 AM.

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"