+ Reply to Thread
Results 1 to 4 of 4

Macro to copy six specific columns from one worksheet to another worksheet

  1. #1
    Forum Contributor
    Join Date
    02-09-2004
    Location
    Cardiff - Wales - UK
    MS-Off Ver
    2013
    Posts
    474

    Question Macro to copy six specific columns from one worksheet to another worksheet

    Hi,

    What I am trying to do is to write a macro that will automatically copy six columns from worksheet (Sheet 1) to another worksheet (Sheet 2). i.e. ‘Description of Project’, ‘WBS Code’, ‘Rate’, ‘Employee Name’, ‘Premium’, ‘Invoice’, ‘Status’, ‘Total Cumulative Hours’, ‘Total Cumulative Amount’ from Worksheet (from Sheet 1 to Sheet 2)

    The problem arises as I know the names of the columns to be copied in Sheet 1 (as details above) but they can be in any order in sheet 1.

    In additional the columns ‘Total Cumulative Hours’, ‘Total Cumulative Amount’ are total columns so when they are copied from ‘Sheet 1’ to ‘Sheet 2’ their values should be copied as opposed to the formulas

    Any assistance would be greatly appreciated

    Excel version 2003

    Many thanks


    Rob
    Rob

  2. #2
    Valued Forum Contributor Dunc3142's Avatar
    Join Date
    09-05-2007
    Location
    Franklin OH
    MS-Off Ver
    2000 and 2007 and 2010 @ Home & Teach 2010
    Posts
    351

    Try this

    Start recording your macro. Search for the column heading. in the column heading cell press Ctrl+Shift+Down (select column) arrow to select the column. Copy that column, move to the other sheet and paste, (if this is the column with thw formulas use Paste Special, Values)
    switch back to the first sheet and search for the next heading and repeat.
    Yes it will. we just have to figure out how...
    If I have helped you, PLEASE click the * and add to my Rep.
    Also, if the problem is SOLVED please mark it as so.

  3. #3
    Registered User
    Join Date
    05-08-2011
    Location
    India, Mumbai
    MS-Off Ver
    Excel 2010
    Posts
    59

    Red face Re: Try this

    Dear Excel Guru,
    Great!! It’s working fine where all the columns are filled completely/ entirely, however, incomplete filled column (s) been copying only upto blank cell not entirely for example…
    Actual Column
    IMO
    3



    2



    2

    Copying Column after running recorded macro
    IMO
    3

    Please give me solution
    Excel file (SPARCS 244_COPY MACRO) is attached for your ready ref

    Ravi

  4. #4
    Registered User
    Join Date
    05-08-2011
    Location
    India, Mumbai
    MS-Off Ver
    Excel 2010
    Posts
    59

    Re: Macro to copy six specific columns from one worksheet to another worksheet

    Pl. help me

+ 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