+ Reply to Thread
Results 1 to 4 of 4

How do I keep the VBA with a copied worksheet

  1. #1
    Registered User
    Join Date
    09-21-2007
    Posts
    20

    How do I keep the VBA with a copied worksheet

    Hi

    I have a worksheet with a command button that when clicked copies the worksheet, saves the copy and mails the copied worksheet to another user.

    this was written using Excel 2003 the command button works and copies the code onto the new sheet. When this is used by an Excel 2002 user the code disappears from the copied sheet.....How do i keep it there?

    Thanks in advance Shaun

  2. #2
    Forum Expert royUK's Avatar
    Join Date
    11-18-2003
    Location
    Derbyshire,UK
    MS-Off Ver
    Xp; 2007; 2010
    Posts
    26,200
    IKt depends on what type of code it is. If it is in the Worksheet module then it will copy, if not you need to copy the workbook & delete unwanted sheets from the copy.
    Hope that helps.

    RoyUK
    --------
    For Excel Tips & Solutions, free examples and tutorials why not check out my web site

    Free DataBaseForm example

  3. #3
    Registered User
    Join Date
    09-21-2007
    Posts
    20
    Hi

    the code is attached to the worksheet, and works on my machine with 2003...when it is used by someone else,an excel 2002 user the code does not copy... could this need the references changed (most are version 11)?

    Shaun

  4. #4
    Forum Expert royUK's Avatar
    Join Date
    11-18-2003
    Location
    Derbyshire,UK
    MS-Off Ver
    Xp; 2007; 2010
    Posts
    26,200
    It depends what the code is doing? can you attach an example workbook/

+ 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