Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2
Default Macro for changing tabs

First you need to count the number of sheets you have, then
Starting at the last, increment it first. Something like:

NumberSheets = Sheets.Count
Sheets.Add
For X = NumberSheets to 1 Step -1

Sheets(x).Select
Sheets(x).Name = "Week" & X
Next X

If you change Week1 to 2 before 2 is changed you will have conflict.

Alan

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
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
Chart tabs changing by themself Elardus Charts and Charting in Excel 4 February 12th 10 01:42 AM
Run Macro when changing tabs Supe Excel Discussion (Misc queries) 2 December 31st 08 10:51 PM
Changing Tabs to Specific Cells Darren Excel Discussion (Misc queries) 2 November 10th 05 04:21 AM
Changing colors of tabs Christopher Anderson Excel Discussion (Misc queries) 2 November 29th 04 04:09 PM
Macro for changing tabs Chip Pearson Excel Programming 5 February 12th 04 08:17 PM


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