+ Reply to Thread
Results 1 to 3 of 3

Macro for Copy Sheet+Rename

  1. #1
    Registered User
    Join Date
    10-03-2010
    Location
    Tennessee, USA
    MS-Off Ver
    Excel 2002
    Posts
    2

    Macro for Copy Sheet+Rename

    I have to make a macro run under a windows excel and Visual Basic is not exactly basic.

    Can anyone help with some code? It would be awesome if the macro did this:
    Copy worksheet
    Rename new worksheet to current date set by the computers date and time
    Reset the first worksheet back to the original (the version before you filled cells in)
    Sort sheet tabs in ascending order according to date (1st - 31st)

    Pretty simple apparently, VB is just not my interface of choice.
    Any ideas?.

  2. #2
    Forum Guru
    Join Date
    03-02-2006
    Location
    Los Angeles, Ca
    MS-Off Ver
    WinXP/MSO2007;Win10/MSO2016
    Posts
    12,624

    Re: Macro for Copy Sheet+Rename

    The code below is very basic, just to get you started. It assumes that the variable data is entered in cells A1 through E1

    Please Login or Register  to view this content.
    To Insert a module and copy code:
    1. Copy the Excel VBA code that you want to use
    2. Select the workbook in which you want to store the Excel VBA code
    3. Hold the Alt key, and press the F11 key, to open the Visual Basic Editor
    4. Choose Insert | Module
    5. Where the cursor is flashing, choose Edit | Paste
    Last edited by protonLeah; 10-03-2010 at 05:02 PM.
    Ben Van Johnson

  3. #3
    Registered User
    Join Date
    10-03-2010
    Location
    Tennessee, USA
    MS-Off Ver
    Excel 2002
    Posts
    2

    Re: Macro for Copy Sheet+Rename

    Ah Thanks so much Ben!!
    This helps me so much, I have this as an app I made in OSX, I just cant make any sense out of VB.
    Let me get this going and ill post up if theres any issues I run into -- Im not a programmer, so I am learning on the fly.

+ 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