+ Reply to Thread
Results 1 to 4 of 4

Automatically copy an entire row to another sheet if a cell displays a specific value

  1. #1
    Registered User
    Join Date
    09-19-2018
    Location
    Bel Air, MD
    MS-Off Ver
    2013
    Posts
    2

    Question Automatically copy an entire row to another sheet if a cell displays a specific value

    I am trying to set up an automatic inventory. On sheet 1 I have my master inventory, Columns A-G, and I want to make it so depending on what location (column B) is listed, it will automatically copy the entire row to another sheet. The values of column B (location) are 1-10 and I want all rows that have a location value of "1" to be copied to sheet 2 (titled Location 1), all rows that have a location value of "2" to be copied to sheet 3 (titled Location 2), etc. Is this possible to make this automatic sheet? Also when a row is added to the master inventory (sheet 1) it needs to be copied automatically. Please let me know if you need any other info.

    Thank you for your help!

  2. #2
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    24,704

    Re: Automatically copy an entire row to another sheet if a cell displays a specific value

    It would help if you attached a sample Excel workbook, so we can see exactly how your data is laid out.

    To do this, click on Go Advanced (below the Edit Window) while you are composing a reply, then scroll down to and click on Manage Attachments and the Upload window will open. Click on Browse and navigate to (and double-click) the file icon that you want to attach, then click on Upload and then on Close this Window to return to the Edit window. When you have finished composing your post, click on Submit Post. Don't try to use the Paperclip icon, as it doesn't work on this forum.

    Hope this helps.

    Pete

  3. #3
    Registered User
    Join Date
    09-19-2018
    Location
    Bel Air, MD
    MS-Off Ver
    2013
    Posts
    2

    Re: Automatically copy an entire row to another sheet if a cell displays a specific value

    I have uploaded an example of the document to my attachments. Sorry for the delay, as I had to block out certain information. Please let me know if you can view the attachment.
    Attached Files Attached Files

  4. #4
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    24,704

    Re: Automatically copy an entire row to another sheet if a cell displays a specific value

    I have used column I on the Master sheet as a helper column (coloured blue), with this formula in I2:

    =IF(B2="","-",B2&"_"&COUNTIF(B$2:B2,B2))

    This should be copied down beyond your data to accommodate more data being added - I've copied to row 200 in the attached file, and the hyphens help to show where the formula is active.

    In all the Location sheets I have used cell M1 to record the location number for each sheet (1 to 9), and then put this formula in A2:

    =IFERROR(INDEX('Master Inventory'!A:A,MATCH($M$1&"_"&ROWS($1:1),'Master Inventory'!$I:$I,0)),"")

    This can be copied across to column H, and then down as far as you like - I've copied to row 20 in all sheets, though it needs to be copied further than this in some sheets in order to see all the data.

    As this is a formula solution, it will automatically pick up new data that is added to the Master sheet and show it in the appropriate Location sheet.

    Hope this helps.

    Pete
    Attached Files Attached Files

+ 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: 3
    Last Post: 02-04-2017, 09:03 PM
  2. automatically copy entire row to other sheet if ID is found.
    By Just64 in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 09-23-2015, 01:46 AM
  3. Replies: 3
    Last Post: 10-31-2013, 03:41 PM
  4. If cell contains specific text automatically copy row to different sheet
    By donnzi in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 10-18-2013, 03:41 AM
  5. [SOLVED] copy paste entire row into a specific cell in sheet 2
    By melody10 in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 09-29-2013, 04:40 PM
  6. How do I copy an entire row to another sheet determined by a specific value?
    By Golfer1105 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 04-03-2013, 05:54 AM
  7. [SOLVED] Macro Help: IF specific wording is found in a cell, THEN copy entire row to new sheet
    By csch123 in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 06-13-2012, 03:16 PM

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