I want to have a code to copy the worksheet called "invoice" and once it is
copied I want it to change its name to what ever is in cells "G13"
Thanks again
Greg
I want to have a code to copy the worksheet called "invoice" and once it is
copied I want it to change its name to what ever is in cells "G13"
Thanks again
Greg
Something like this should work:
Dim Wname As String
Wname = Worksheets("Sheet1").Range("G13")
Worksheets("Sheet1").Copy after:=Worksheets _(Worksheets.Count)
ActiveSheet.Name = Wname
You don't have to use the "after:=Worksheets _(Worksheets.Count)", all
that does is put the new sheet at the end, you can put it wherever you
want.
*** Sent via Developersdex http://www.developersdex.com ***
Hi Greg,
ActiveSheet.Copy Before:=Worksheets(Worksheets.Count)
ActiveSheet.Name = Range("G13").Value
--
HTH
RP
(remove nothere from the email address if mailing direct)
"Greg B" <laptopgb@ihug.com.au> wrote in message
news:d6d5rl$tle$1@lust.ihug.co.nz...
> I want to have a code to copy the worksheet called "invoice" and once it
is
> copied I want it to change its name to what ever is in cells "G13"
>
> Thanks again
>
> Greg
>
>
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks