Copiyng From one sheet to the other (excel)

Posted on 2006-03-22
Last Modified: 2012-05-05
Hi everyone,

I have a issue:

In SheetA I have:

Cell A1 = bla bla
Cell F2 = bla bla
Cell G3 = bla bla

Is there any code that can help me to bring the contents of these cells and copy them to

Sheet B

A1 = Sheet cell 1A
B1 = Sheet cell F2
C1 = Sheet cell G3. Because on sheet A this cells will be refreshed cotiniously so I was trynig to insert a commandclick nammed save that every time the user click on the command cotton the contents of these cells should be added on the next sheet in a row and the next time the contents of sheet a should be added again in sheet B but on the next row and so on.

Resume: In sheet a I have: |John | Frederick| class 1b| this should be copied on the second row of sheet b then when I click on the command botton next time will have
|Maurice| Antonius | class 5d| and so on so sheet 2 will be creating lika a sort of list with multiple rows.

Please if anyone can help me I will higly apreciate it .

Thanks Regards

Question by:NEW_INDIA
    LVL 44

    Accepted Solution

    Do this manually, or automated?
    For manual, you just highlight the 3 separate cells you want holding down control key.  then click on new DB tab, and set cursor to A1 and do paste -- three cells copy in sequentially, as you want.

    For automated?  Have to write simple excel command copy A1 F2 G3 table 1 to A1 B1 C1 table 2, and you are done.  If you dont know what cells are to be, then have to write a complex routine to search for data in cells, and this very tough to do.

    Assisted Solution

    write this in an module and then call it with your button.
    Function sheetAUpdate
    Dim ILastrow As Integer
    On Error Resume Next
        ILastrow = Sheets("B").Cells.Find(What:="*", _
          SearchDirection:=xlPrevious, _
          ILastrow = ILastrow + 1
    Sheets("B").Cells(ILastrow, 1) = Sheets("A").Cells(1, 1)
    Sheets("B").Cells(ILastrow, 2) = Sheets("A").Cells(2, 6)
    Sheets("B").Cells(ILastrow, 3) = Sheets("A").Cells(3, 7)
    On Error GoTo 0
    End Function
    regards Stefan

    Featured Post

    Maximize Your Threat Intelligence Reporting

    Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

    Join & Write a Comment

    Suggested Solutions

    Title # Comments Views Activity
    wait notify demo infinite loop 3 69
    maxMirror challenge 10 70
    matchUp  challenge 9 52
    array11 challenge 16 40
    This is an explanation of a simple data model to help parse a JSON feed
    In this post we will learn how to connect and configure Android Device (Smartphone etc.) with Android Studio. After that we will run a simple Hello World Program.
    Viewers will learn how to properly install Eclipse with the necessary JDK, and will take a look at an introductory Java program. Download Eclipse installation zip file: Extract files from zip file: Download and install JDK 8: Open Eclipse and …
    In this fifth video of the Xpdf series, we discuss and demonstrate the PDFdetach utility, which is able to list and, more importantly, extract attachments that are embedded in PDF files. It does this via a command line interface, making it suitable …

    746 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    14 Experts available now in Live!

    Get 1:1 Help Now