+ Reply to Thread
Results 1 to 4 of 4

Macro for copying the data from one sheet and insert the same in next sheet

  1. #1
    Registered User
    Join Date
    09-21-2013
    Location
    chennai,India
    MS-Off Ver
    Excel 2010
    Posts
    75

    Macro for copying the data from one sheet and insert the same in next sheet

    Hi All,

    i have a workbook with two sheets named "sheet1" and "sheet2".If i insert anything in sheet 1, that should automatically populate in sheet 2.

    I have a column name as "status" in sheet 1.

    If i insert anything in sheet 1, that should automatically populate in sheet 2 is my primary target.But if i update the status column in sheet 1 that should highlight that particular row/cell in sheet 2 expect the status "Resolved". If the status in sheet 1 is updated as resolved, then the specific row in sheet 2 should be deleted.

    Please help me..., Thanks in Advance..

  2. #2
    Forum Guru HaHoBe's Avatar
    Join Date
    02-19-2005
    Location
    Hamburg, Germany
    MS-Off Ver
    work: 2016 on Win10 (notebook), private: 365 on Win11 (desktop), 2019 on Win11 (notebook)
    Posts
    8,198

    Re: Macro for copying the data from one sheet and insert the same in next sheet

    Hi, Thinker8,

    sounds that you are looking to use the Worksheet_Change-event behind Sheet1 but you need to be more specific about
    I have a column name as "status" in sheet 1.
    You certainly can give the number of the Column.

    Please Login or Register  to view this content.
    Maybe you think about using the Sheet_Activate-event for Sheet2 to go through the code only when you will have a look at Sheet2 or tell us about the number of records we are talking about.

    Ciao,
    Holger
    Use Code-Tags for showing your code: [code] Your Code here [/code]
    Please mark your question Solved if there has been offered a solution that works fine for you

  3. #3
    Registered User
    Join Date
    09-21-2013
    Location
    chennai,India
    MS-Off Ver
    Excel 2010
    Posts
    75

    Re: Macro for copying the data from one sheet and insert the same in next sheet

    Hi Ciao,

    Both the sheet has same count of columns.Status column number is 10.

    First it should copy the data from sheet 1 to sheet 2.(I meant to say is if i insert a data).
    After it was inserted in sheet 2 , if i made any change in the column status in sheet 1 it should highlight that row in sheet 2 but the status was updated as "Resolved" in status column that particular row in sheet 2 should be deleted.

    I hope now you are clear with my question.. :P

  4. #4
    Forum Guru HaHoBe's Avatar
    Join Date
    02-19-2005
    Location
    Hamburg, Germany
    MS-Off Ver
    work: 2016 on Win10 (notebook), private: 365 on Win11 (desktop), 2019 on Win11 (notebook)
    Posts
    8,198

    Re: Macro for copying the data from one sheet and insert the same in next sheet

    Hi, Thinker8,

    did you ever try to plot out what requirements are needed for your request? You put in any information into any Column in a new row on Sheet1 the row gets copied over, you put more info in, you need to find the dataset and overwrite the contents, you put in Resolved in COlumn 10 in Sheet1 that row gets deleted on Sheet2 leaving no direct contact to Sheet1 but using Find on a unique ID which you havenīt listed as of yet.

    Iīm glad you didnīt point out for which reason this should be a Worksheet_Change-event type as I donīt know what the data on Sheet2 is needed for. So again: Iīd recommend using the Worksheet_Activate of Sheet2, delete all information, copy over, use Autofilter, delete resolved, unapply Autofilter.

    Ciao,
    Holger

+ 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. Replies: 1
    Last Post: 12-03-2013, 04:19 AM
  2. [SOLVED] Macro for copying data from one column in sheet 2 based on two criterias in sheet 1
    By baardings in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 11-13-2012, 01:50 PM
  3. Copy Sheet / Create & Name New Sheet / Insert Before a Sheet / Paste Data
    By thinkspac in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 10-12-2012, 02:27 PM
  4. Replies: 0
    Last Post: 08-18-2012, 03:06 AM
  5. Insert Data From One Sheet to Another with Macro
    By niladri20005 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 08-30-2011, 08:14 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