Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 244
Default Refer to worksheet

I want to refer to a worksheet that has a certain name. Now I write:

Set rapportWorksheet = "Rapport"

That is I want to somehow be able to use this variable later and refer to
the worksheet by the variable. That way I only have to change the name of the
worksheet once in case I have to do that. Please help me with the syntax.
Thanks very much!
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 415
Default Refer to worksheet

Arne,
Set rapportWorksheet =
ThisWorkbook/Activeworkbook/Workbooks("Whatever").Worksheets("Rapport")

NickHK

"Arne Hegefors" ...
I want to refer to a worksheet that has a certain name. Now I write:

Set rapportWorksheet = "Rapport"

That is I want to somehow be able to use this variable later and refer to
the worksheet by the variable. That way I only have to change the name of
the
worksheet once in case I have to do that. Please help me with the syntax.
Thanks very much!



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 644
Default Refer to worksheet

Set rapportWorksheet = Sheets("Rapport")

HTH

Charles

Arne Hegefors wrote:
I want to refer to a worksheet that has a certain name. Now I write:

Set rapportWorksheet = "Rapport"

That is I want to somehow be able to use this variable later and refer to
the worksheet by the variable. That way I only have to change the name of the
worksheet once in case I have to do that. Please help me with the syntax.
Thanks very much!


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
refer to last cell in worksheet? svh646 Excel Worksheet Functions 2 July 25th 06 01:23 AM
Refer to more than one worksheet in a workbook Göran M Excel Worksheet Functions 0 January 2nd 06 07:02 AM
variable to refer to "this worksheet"? confused Excel Worksheet Functions 1 June 16th 05 11:51 PM
Refer to Excel Worksheet by its name RichB Excel Worksheet Functions 2 February 5th 05 01:07 PM
Formula to refer to other worksheet... Liz-In-USA Excel Worksheet Functions 4 November 9th 04 10:51 PM


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