+ Reply to Thread
Results 1 to 4 of 4

how to copy contents of one column to another column in another worksheet

  1. #1
    yefei
    Guest

    how to copy contents of one column to another column in another worksheet

    should i use VBA to do this?
    i need to copy the content of a column in one worksheet to another, if
    the content in the cell is not empty. and when i add a macro, the sub
    procedure ask me to pass in object, is it way like this:

    sub copyAnswer(workbook, worksheet)
    end sub

    because the default one is
    sub copyAnswer()
    end sub


  2. #2
    Don Guillett
    Guest

    Re: how to copy contents of one column to another column in another worksheet

    try

    Sub copycol()
    Sheets("sheet1").Columns("a").Copy _
    Sheets("sheet2").Columns("a")
    End Sub
    --
    Don Guillett
    SalesAid Software
    [email protected]
    "yefei" <[email protected]> wrote in message
    news:[email protected]...
    > should i use VBA to do this?
    > i need to copy the content of a column in one worksheet to another, if
    > the content in the cell is not empty. and when i add a macro, the sub
    > procedure ask me to pass in object, is it way like this:
    >
    > sub copyAnswer(workbook, worksheet)
    > end sub
    >
    > because the default one is
    > sub copyAnswer()
    > end sub
    >




  3. #3
    yefei
    Guest

    Re: how to copy contents of one column to another column in another worksheet

    thsnak very much
    another issue
    how to get rid of part of the text in a cell?
    for example, if a cell contains "welcome", then i remoce it, and copy
    the rest content of the cell to somewhere else.


  4. #4
    Don Guillett
    Guest

    Re: how to copy contents of one column to another column in another worksheet

    Glad to help. Have a look at help indes for REPLACE and/or SUBSTITUTE

    --
    Don Guillett
    SalesAid Software
    [email protected]
    "yefei" <[email protected]> wrote in message
    news:[email protected]...
    > thsnak very much
    > another issue
    > how to get rid of part of the text in a cell?
    > for example, if a cell contains "welcome", then i remoce it, and copy
    > the rest content of the cell to somewhere else.
    >




+ 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