+ Reply to Thread
Results 1 to 4 of 4

renaming sheets

  1. #1
    Kjeldc
    Guest

    renaming sheets

    How do I rename a worksheet like this:
    Original name + (Year-1)
    I want to save some worksheets when a new year starts and use the old name
    again on a new empty sheet

  2. #2
    somethinglikeant
    Guest

    Re: renaming sheets

    Sub RenameSheet()
    x = WorksheetFunction.Text(Now(), "YYYY") - 1
    ActiveSheet.Name = ActiveSheet.Name & " " & x
    End Sub

    This code performs this operation on the current activesheet

    somethinglikeant


  3. #3
    Ron de Bruin
    Guest

    Re: renaming sheets

    Hi Kjeldc

    Try this
    ActiveSheet.Name = ActiveSheet.Name & " " & Year(Date) - 1


    --
    Regards Ron de Bruin
    http://www.rondebruin.nl


    "Kjeldc" <kjeldc(Remove)@tdcadsl.dk> wrote in message news:[email protected]...
    > How do I rename a worksheet like this:
    > Original name + (Year-1)
    > I want to save some worksheets when a new year starts and use the old name
    > again on a new empty sheet




  4. #4
    Kjeldc
    Guest

    Re: renaming sheets

    Thank you, both of you. Just what I wanted ;-)

    "Ron de Bruin" skrev:

    > Hi Kjeldc
    >
    > Try this
    > ActiveSheet.Name = ActiveSheet.Name & " " & Year(Date) - 1
    >
    >
    > --
    > Regards Ron de Bruin
    > http://www.rondebruin.nl
    >
    >
    > "Kjeldc" <kjeldc(Remove)@tdcadsl.dk> wrote in message news:[email protected]...
    > > How do I rename a worksheet like this:
    > > Original name + (Year-1)
    > > I want to save some worksheets when a new year starts and use the old name
    > > again on a new empty sheet

    >
    >
    >


+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1