LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Macro (Codes)


Hi people, im quite new to macros and theres a few things i need to do
which cant be done using the 'record new macro' function. So does
anyone know a code for:
1)'selecting the second to last sheet of all the worksheets'
2)'selecting the 5th sheet infront of the current sheet'
3)'selecting the 1st sheet infront of the current sheet'

To make it more undastandable heres some examples;

1) total number of 7 sheets, 'A', 'B', 'C'...'F', 'G' - Select sheet
'F'. Im going to have to use this code every week, therfore i cannot
just write a code like 'select sheet F' because everyweek it would be a
different name (because my sheets are named by dates, e.g. M-13.06.05)

2) the current sheet is 'F' - the 5th sheet infront of sheet 'F' would
be sheet 'A'. Similar to above i cant use the code 'select sheet 'A'.

3) the current sheet is 'F' - the 1th sheet infront of sheet 'F' would
be sheet 'E'. Similar to above i cant use the code 'select sheet 'A'.

If you need the actualy names of the sheets because of any reasons they
are (in order of the 7 sheets);
'M-13.06.05', 'Tu-14.06.05', 'W-15.06.05', 'Th-16.06.05', 'F-17.06.05',
'WSR-13.06.05 - 17.06.05', 'WSP-13.06.05 - 17.06.05'.

If there is no such code, please tell me is there any similar ways?

Any help would be hugely appreciated,
Bonbon =)


--
Bonbon
------------------------------------------------------------------------
Bonbon's Profile: http://www.excelforum.com/member.php...o&userid=31866
View this thread: http://www.excelforum.com/showthread...hreadid=515940

 
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
macro codes peyman Excel Discussion (Misc queries) 4 September 18th 07 10:28 PM
Need some macro codes zen65 Excel Discussion (Misc queries) 4 May 24th 07 06:15 PM
Macro codes security H.Ali Dogan Excel Programming 1 September 9th 05 05:31 PM
VBA codes for macro to continue Brian Excel Programming 11 May 23rd 05 11:33 PM
PSW for Macro & Codes Metallo[_4_] Excel Programming 4 July 13th 04 08:08 PM


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