Sheet Codenames

  • Follow


Hi everyone,

I've got a workbook in which other users may rename sheets so I want to 
change all tab names to codenames in VBA modules.

I've read that I can do it using Find/Replace in the VBE but what I wanted 
to know is whether I need to tell it I'm using the codename for sheets.

If I have to (or should) how would I do it?
-- 
Thank you
Annie
0
Reply Utf 2/4/2010 8:17:02 PM

Hi Annie

With a worksheet level sheet name the syntax is:

Worksheets("Sheet1").Select

With a VBA level code names the syntas is:

Sheet1.Select

Hopes this helps.
....
Per

"Annie Whitley" <AnnieWhitley@discussions.microsoft.com> skrev i meddelelsen 
news:EBB5464D-A04F-4170-BDDD-BF637A25157B@microsoft.com...
> Hi everyone,
>
> I've got a workbook in which other users may rename sheets so I want to
> change all tab names to codenames in VBA modules.
>
> I've read that I can do it using Find/Replace in the VBE but what I wanted
> to know is whether I need to tell it I'm using the codename for sheets.
>
> If I have to (or should) how would I do it?
> -- 
> Thank you
> Annie 

0
Reply Per 2/4/2010 8:23:19 PM


That did help thank you Per :-)
-- 
Thank you
Annie


"Per Jessen" wrote:

> Hi Annie
> 
> With a worksheet level sheet name the syntax is:
> 
> Worksheets("Sheet1").Select
> 
> With a VBA level code names the syntas is:
> 
> Sheet1.Select
> 
> Hopes this helps.
> ....
> Per
> 
> "Annie Whitley" <AnnieWhitley@discussions.microsoft.com> skrev i meddelelsen 
> news:EBB5464D-A04F-4170-BDDD-BF637A25157B@microsoft.com...
> > Hi everyone,
> >
> > I've got a workbook in which other users may rename sheets so I want to
> > change all tab names to codenames in VBA modules.
> >
> > I've read that I can do it using Find/Replace in the VBE but what I wanted
> > to know is whether I need to tell it I'm using the codename for sheets.
> >
> > If I have to (or should) how would I do it?
> > -- 
> > Thank you
> > Annie 
> 
> .
> 
0
Reply Utf 2/5/2010 10:40:05 PM

2 Replies
241 Views

(page loaded in 0.078 seconds)


Reply: