+ Reply to Thread
Results 1 to 4 of 4

Need to transfer form and data to another sheet.

  1. #1
    Registered User
    Join Date
    10-27-2016
    Location
    Cincinnati, Ohio
    MS-Off Ver
    2010
    Posts
    8

    Need to transfer form and data to another sheet.

    I am creating a paycheck stub for employees. After stub is filled and printed I wanted to copy it to sheet 2 including its data including the form itself. 80% of the forms data have answers created by formula. These numbers will not transfer they just fill in as zeros('0'). I have attached the VB code I am using for the transfer. I just can not get the data to transfer as well.
    CODE:
    Sub CopySource()
    Dim rngSource As Range
    Dim rngTarget As Range
    Dim iRow As Integer

    Set rngSource = Worksheets("Sheet1").Range("SourceData")
    iRow = Worksheets("Sheet2").Cells(Rows.Count, 1).End(xlUp).Row + 3
    Set rngTarget = Worksheets("Sheet2").Range("A" & iRow)
    rngSource.Copy Destination:=rngTarget

    Thank you for your help.

  2. #2
    Forum Guru Norie's Avatar
    Join Date
    02-02-2005
    Location
    Stirling, Scotland
    MS-Off Ver
    Microsoft Office 365
    Posts
    19,644

    Re: Need to transfer form and data to another sheet.

    Any chance you could upload a sample workbook?

    Click on GO ADVANCED, scroll down and click Manage Attachments.
    If posting code please use code tags, see here.

  3. #3
    Registered User
    Join Date
    10-27-2016
    Location
    Cincinnati, Ohio
    MS-Off Ver
    2010
    Posts
    8

    Re: Need to transfer form and data to another sheet.

    Any luck as to what I am supposed to do?

  4. #4
    Forum Expert Logit's Avatar
    Join Date
    12-23-2012
    Location
    North Carolina
    MS-Off Ver
    Excel 2019 Professional Plus - 2007 Enterprise
    Posts
    7,409

    Re: Need to transfer form and data to another sheet.

    xlPasteSpecial

    https://msdn.microsoft.com/en-us/lib...ffice.11).aspx

    Another discussion

    http://stackoverflow.com/questions/1...ulas-excel-vba

    You could edit this code to work for you:

    Please Login or Register  to view this content.
    Attached Files Attached Files

+ 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. [SOLVED] Transfer data from form to Response Data sheet
    By Wskip49 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 07-08-2015, 06:42 PM
  2. [SOLVED] Transfer data from form to next sheet in NEXT AVAILABLE COLUMN
    By sfryeben in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 05-06-2014, 05:03 PM
  3. Using VBA to transfer data from Excel form to a web form. error 'Permission Denied'
    By danieldowds in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 03-14-2014, 08:14 AM
  4. Unable to transfer data from user form to spread sheet
    By katieshields in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 02-19-2014, 05:43 AM
  5. Macro to transfer data from Input sheet to summary form
    By CA_needing_help in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 07-04-2013, 03:14 AM
  6. Transfer User form data to a worksheet w.r.t. combobox item on the form
    By nm766 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 02-07-2011, 12:43 PM
  7. Macro To Transfer Form to New Sheet and Data to Another Sheet
    By kokoynonoy in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 01-11-2011, 10:36 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