+ Reply to Thread
Results 1 to 5 of 5

Copy user mentioned column from first sheet to another mentioned column in second sheet

  1. #1
    Registered User
    Join Date
    10-10-2012
    Location
    india
    MS-Off Ver
    Excel 2007
    Posts
    3

    Copy user mentioned column from first sheet to another mentioned column in second sheet

    Dear Friends,

    Here is the problem statement:
    I have the first data sheet called "data" which has multiple columns. I want to copy certain columns from this sheet to H1 and H2 depending upon the mapping provided in the mapping sheet.

    If the mapping looks like:
    From Data to H1
    B A
    then i want to copy the contents of column B from "data" sheet to column A of "H1" sheet

    I have uploaded the excel doc on how the output should look like.

    Would appreciate if someone can share macro/sample code/sample excel sheet on how to do this.

    Regards
    rpatil
    Attached Files Attached Files
    Last edited by rpatil; 10-11-2012 at 12:40 AM.

  2. #2
    Forum Contributor arlu1201's Avatar
    Join Date
    09-09-2011
    Location
    Bangalore, India
    MS-Off Ver
    Excel 2003 & 2007
    Posts
    19,166

    Re: Copy user mentioned column from first sheet to another mentioned column in second shee

    In the mapping sheet, will your data always be in the middle of your sheet? Or will it be starting in A1?

    If its in the middle of the sheet, it can make your code more cumbersome.
    If I have helped, Don't forget to add to my reputation (click on the star below the post)
    Don't forget to mark threads as "Solved" (Thread Tools->Mark thread as Solved)
    Use code tags when posting your VBA code: [code] Your code here [/code]

  3. #3
    Registered User
    Join Date
    10-10-2012
    Location
    india
    MS-Off Ver
    Excel 2007
    Posts
    3

    Re: Copy user mentioned column from first sheet to another mentioned column in second shee

    HI Arlette

    The mapping will start from A1.
    There are 3 mappings and this is how it will look like

    Cell A B C D E F
    Data - H1 Data-H2 Data-H3

    THis will be followed by number or column entries which needs to be copied from Data to H1/H2/H3

  4. #4
    Forum Contributor arlu1201's Avatar
    Join Date
    09-09-2011
    Location
    Bangalore, India
    MS-Off Ver
    Excel 2003 & 2007
    Posts
    19,166

    Re: Copy user mentioned column from first sheet to another mentioned column in second shee

    So just 6 columns in the mapping sheet right?

  5. #5
    Registered User
    Join Date
    10-10-2012
    Location
    india
    MS-Off Ver
    Excel 2007
    Posts
    3

    Re: Copy user mentioned column from first sheet to another mentioned column in second shee

    Dear Arlette,

    I have uploaded one more document - updated the sample document!
    yes there willl be only 6 columns in the mapping file. But the thing is the entry in each column in data sheet will go upto 150-200 rows.
    The entries in the mapping sheet also could go upto 100 entries.
    so the idea is to copy the whole column to new sheets.

    Really appreciate your help in this. I am very much a novice in this macro/vba and need this to be done for urgent and important purpose,
    Thanks
    Regards - rpatil

+ 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