+ Reply to Thread
Results 1 to 5 of 5

Copy cell if cells in a range contain specific text

  1. #1
    Registered User
    Join Date
    01-16-2014
    Location
    Derby, England
    MS-Off Ver
    Excel 2010
    Posts
    48

    Copy cell if cells in a range contain specific text

    Hi all,

    I have a range of data, that basically details dates, customers, hours and staff. Attached a sample sheet.


    I need a formula (or code) that separates each staff member's jobs and the hours. (Columns J converts the hours into a number and K split the hours down to how many each member staff does)

    In columns O to Q, I have put the results I hope to achieve. (this will then be repeated for each staff member).

    Any help would be appreciated.
    Attached Files Attached Files

  2. #2
    Forum Expert
    Join Date
    07-20-2011
    Location
    Mysore, India.
    MS-Off Ver
    Excel 2019
    Posts
    8,587

    Re: Copy cell if cells in a range contain specific text

    Pl See file
    In S4
    Please Login or Register  to view this content.
    In T4
    Please Login or Register  to view this content.
    In U4
    Please Login or Register  to view this content.
    Drag all Down words.

    Then Copy the whole range S4:U14 and paste it to other regions.
    Attached Files Attached Files
    Pl note
    Array formula should be confirmed with Ctrl+Shift+Enter keys together.
    If answere is satisfactory press * to add reputation.

  3. #3
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: Copy cell if cells in a range contain specific text

    If you are prepared to rejig your data into a normalised table that can be used by a Pivot Table then you have far more flexibility and don't need any formulae to obtain the results.

    I've also added three Slicers so that you are able to filter the data by selecting one or more values from a Slicer.

    See attached
    Attached Files Attached Files
    Richard Buttrey

    RIP - d. 06/10/2022

    If any of the responses have helped then please consider rating them by clicking the small star icon below the post.

  4. #4
    Registered User
    Join Date
    01-16-2014
    Location
    Derby, England
    MS-Off Ver
    Excel 2010
    Posts
    48

    Re: Copy cell if cells in a range contain specific text

    Thank you both for your responses. It's very much appreciated.

  5. #5
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: Copy cell if cells in a range contain specific text

    My pleasure and thanks for the rep.

+ 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. [SOLVED] Copy cells in a specific range or column if cell value is greater/less than a value?
    By Kamal1234 in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 03-07-2018, 11:30 AM
  2. [SOLVED] VBA to add text into a range of cells if another cell has a specific value
    By steve64 in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 02-21-2016, 03:15 PM
  3. [SOLVED] VBA to Find Specific Text, then Copy range to next open cell under specific text
    By Remotruker in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 02-24-2015, 10:59 AM
  4. Auto-copy cells with specific text-content in cell below
    By jandekeersmaecker in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 12-28-2013, 12:52 PM
  5. Check cell Value in range and copy specific cells to another sheet
    By jmethejedi in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 07-08-2013, 06:25 PM
  6. [SOLVED] Highlight a range of cells if a single cell contains specific text
    By ZHertz in forum Excel General
    Replies: 3
    Last Post: 10-19-2012, 02:54 PM
  7. How to copy a range of columns from sheet1 to sheet2 if the cell show a specific text
    By chermaine123 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 09-21-2011, 02:39 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