View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.programming
marksince1984[_6_] marksince1984[_6_] is offline
external usenet poster
 
Posts: 1
Default using variables to reference sheets


Can you clarify this a bit more for me??

Everytime the macro is run the variable may be different.

Ie there could be five sheets with names mon, tues, wed. Tomorrow the
could be tues, wed, thurs. I need to be able to call these sheets (b
using the variable)

Sorry but i am still new to this





Bob Phillips Wrote:
Don't set it to the worksheet name, set it to the worksheet object

Set sh = Worksheets("Sheet1")

...

TableDestination = sh.Range("A10").Value

--

HTH

Bob Phillips

(replace xxxx in the email address with gmail if mailing direct)



--
marksince198
-----------------------------------------------------------------------
marksince1984's Profile: http://www.excelforum.com/member.php...fo&userid=3348
View this thread: http://www.excelforum.com/showthread.php?threadid=55122