+ Reply to Thread
Results 1 to 5 of 5

Copy and paste from worksheet to another

  1. #1
    Registered User
    Join Date
    02-15-2014
    Location
    metro manila, philippines
    MS-Off Ver
    Excel 2007 & 10
    Posts
    43

    Copy and paste from worksheet to another

    Hi ExcelForum Members,

    Please help me. I have worksheets:
    w1:= "Sales and Inventory System"
    w2:= "Sales Summary"

    In w1, the user will encode the details of sales. If user clicked the botton "Record to Sales", the details of sales will be recorded at w2.

    W2 is the record/log of sales.


    Here's the sample of my code.


    Please Login or Register  to view this content.


    For a better view of my problem, i attached my files.


    Thanks in advance!







    Sales and Inventory System.xlsmSalesSummary.xlsx
    Last edited by dondonordas; 08-03-2015 at 09:41 PM.

  2. #2
    Registered User
    Join Date
    09-24-2013
    Location
    Poland
    MS-Off Ver
    Excel 2010
    Posts
    22

    Re: Copy and paste from worksheet to another

    You have 1 mistake in Your code:
    You set the value lr from file SalesSummary.xlsx, because after open this file, it is active, and you don't specify in which file macro set the value to lr variable, so it makes it from active sheet in active workbook

  3. #3
    Forum Moderator zbor's Avatar
    Join Date
    02-10-2009
    Location
    Croatia
    MS-Off Ver
    365 ProPlus
    Posts
    15,614

    Re: Copy and paste from worksheet to another

    Your post does not comply with Rule 3 of our Forum RULES. Use code tags around code.

    Posting code between [CODE]Please [url=https://www.excelforum.com/login.php]Login or Register [/url] to view this content.[/CODE] tags makes your code much easier to read and copy for testing, it also maintains VBA formatting.

    Highlight your code and click the # icon at the top of your post window. More information about these and other tags can be found here



    (This thread should receive no further responses until this moderation request is fulfilled, as per Forum Rule 7)

  4. #4
    Registered User
    Join Date
    02-15-2014
    Location
    metro manila, philippines
    MS-Off Ver
    Excel 2007 & 10
    Posts
    43

    Re: Copy and paste from worksheet to another

    Thank you for your response hudibyk but would you help me to figure out the code that activate the lr function in worksheet where it should pick up the inputs? Thank in advance!

  5. #5
    Registered User
    Join Date
    02-15-2014
    Location
    metro manila, philippines
    MS-Off Ver
    Excel 2007 & 10
    Posts
    43

    Re: Copy and paste from worksheet to another

    I tried to insert code within the loop to activate the worksheet where the inputs picks but then the result the same. What code should i includes?

    Thank you in advance hudibyk!

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Copy current month named worksheet and paste into a static worksheet
    By Jissenka in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 01-26-2015, 11:28 PM
  2. Replies: 5
    Last Post: 11-10-2014, 11:49 PM
  3. VBA Match Cell Range to Worksheet Name and copy/paste to respective worksheet
    By rlsublime in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 10-24-2014, 04:06 PM
  4. Match Cell Value to Worksheet Name Then Copy/ Paste Range to Worksheet
    By matt2072 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 05-31-2014, 01:23 PM
  5. [SOLVED] Macro to Copy Master Worksheet create and paste in new auto named worksheet
    By TheRealLethality in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 04-15-2014, 12:46 AM
  6. [SOLVED] Copy data from a worksheet and paste to worksheet with a similar worksheet name
    By maacmaac in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 10-21-2012, 04:02 AM
  7. Copy data from a worksheet and paste to worksheet with a similar worksheet name
    By maacmaac in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 10-21-2012, 02:49 AM

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