+ Reply to Thread
Results 1 to 7 of 7

Cut and Paste a row of data based on the data in a cell

  1. #1
    Forum Contributor
    Join Date
    08-22-2013
    Location
    Kent, England
    MS-Off Ver
    Excel 2010
    Posts
    157

    Cut and Paste a row of data based on the data in a cell

    Hi Everyone,

    Is it possible to have Excel cut and paste a row of data if a cell in that row contains the word "YES"?

    I am unable to attach files at all due to problems with my PC but I will give as much info as I can here, if any more is needed please ask and I will give any information you need.

    The tab that I want the rows to be cut from is called "Master Tracker" and the tab I want them to be pasted into is called "Released"

    The column that will have the word "YES" written in is column "K".

    The rows that will be cut and pasted will be anywhere from row 10+.

    I want the whole row to be cut and pasted if the value in column K for that specific row is "YES".

    Thank you very much in advance,

    Alex

  2. #2
    Forum Contributor wakeupcall's Avatar
    Join Date
    02-29-2012
    Location
    Sofia, Bulgaria
    MS-Off Ver
    Excel 2010
    Posts
    155

    Re: Cut and Paste a row of data based on the data in a cell

    Hi Alex,

    I believe this should work

    Please Login or Register  to view this content.
    Last edited by wakeupcall; 11-21-2013 at 06:51 AM.
    Liked the answer given? click * to say so

  3. #3
    Forum Contributor
    Join Date
    08-17-2013
    Location
    India
    MS-Off Ver
    Excel 2007
    Posts
    132

    Re: Cut and Paste a row of data based on the data in a cell

    Hi Alex,

    This code will start checking "Yes" starting from K1 till last available data cell in that column and will move all "Yes" marked data to next sheet.

    It will then remove the blank rows from the master tracker sheet.

    Please Login or Register  to view this content.
    Regards,
    BS

  4. #4
    Forum Contributor
    Join Date
    08-22-2013
    Location
    Kent, England
    MS-Off Ver
    Excel 2010
    Posts
    157

    Re: Cut and Paste a row of data based on the data in a cell

    Hi, thank you both for replying, it is much appreciated.

    I am a complete "noob" (for want of a better word) when it comes to VBA and I have no idea where I am supposed to insert the code or which cell I should be clicked on when I insert it (if that matters). I also have no idea how to save the code or how to run it and keep it running whenever my worksheet is open.

    If you could talk me through it I would be extremely grateful.

    Thanks again,

    Alex

  5. #5
    Forum Contributor wakeupcall's Avatar
    Join Date
    02-29-2012
    Location
    Sofia, Bulgaria
    MS-Off Ver
    Excel 2010
    Posts
    155

    Re: Cut and Paste a row of data based on the data in a cell

    Hi Alex,

    Whichever code you decide to use, you should copy/paste it in ThisWorkbook object of your excel file.

    When you open the VB Editor (Developer tab --> Visual Basic), on the left you should see a Project Window showng a set of hierchies. Select the one that says VBA Project and the name of you file in brackets. When you open the Microsoft Excel Objects folder you will see ThisWorkbook object.

    As to the running of the macro - you have several options
    1) Run it from View tab---> Macros --> Open macros -->selecting macros stored in ThisWorkbook and the name of the macro
    2) The other option is to assign it to a button to be inserted somewhere in your workbook

    For more instructions how to assign macro to a button (or have the Developer tab displayed if it is currently not), you can refer to
    http://office.microsoft.com/en-us/ex...rms_toolbar%29

  6. #6
    Forum Expert
    Join Date
    06-12-2012
    Location
    Ridgefield Park, New Jersey
    MS-Off Ver
    Excel 2003,2007,2010
    Posts
    10,241

    Re: Cut and Paste a row of data based on the data in a cell

    Another:

    Please Login or Register  to view this content.

  7. #7
    Forum Contributor
    Join Date
    08-22-2013
    Location
    Kent, England
    MS-Off Ver
    Excel 2010
    Posts
    157

    Re: Cut and Paste a row of data based on the data in a cell

    Thank you very much :D

+ 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. Copy and paste discrete data based on cell value using VBA
    By meincontroller in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 08-15-2013, 09:27 AM
  2. [SOLVED] Copy and paste discrete data based on cell value using VBA
    By newbi004 in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 08-14-2013, 03:12 PM
  3. Copy and Paste Data based on a value within a cell
    By gally in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 07-01-2013, 04:43 AM
  4. Open file based on cell value and paste data
    By aller01 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 01-18-2011, 04:29 PM
  5. Paste data into cell based on date variables
    By tanewha69 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 09-05-2006, 06:44 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