VBA- Move Row to Another Sheet Based on Text- Multiple Sheets

sbentley

New Member
Joined
Sep 18, 2019
Messages
1
Hello,

Forgive me, this is my first time working with VBA. I have done my fair share of Googling but have not found a solution. I am trying to get my workbook to move an entire row of data from one sheet to another based on the text found in a column. I was able to figure this out- to an extent. Currently my workbook will move the row (and delete the empty row) to a sheet titled "Complete" if "Delivery Scheduled" is entered in column AJ.

Question: Is it possible to have the text in column AJ determine which sheet the row moves to with each selection moving to a different sheet?

Example: The first sheet would contain a list of files and have an outcome status entered in column AJ by the user.
The data entered here would determine what sheet the row would move to (with each selection routing to a separate sheet).


Text entered into column AJ:Sheet Title row is moved to:
Delivery ScheduledComplete
Intake PrepIntake Prep
IVIV

<tbody>
</tbody>

Is this possible? Thank you in advance!
 

Some videos you may like

Excel Facts

How to calculate loan payments in Excel?
Use the PMT function: =PMT(5%/12,60,-25000) is for a $25,000 loan, 5% annual interest, 60 month loan.

JLGWhiz

Well-known Member
Joined
Feb 7, 2012
Messages
11,679
Office Version
2013
Platform
Windows
There are several ways to do it. You can do it all with code by using a Select Case algorithm or you can use a helper column where you list the destination sheet on the corresponding row to the value in column AJ and simply refer to that range value, eg. If col AK listed the destination sheet and cell AJ25 had 'Delivery Scheduled' value Then
Code:
Range("A25:AJ25").Copy Sheets(Range("AK25").Value).Cells(Rows.Count, 1).End(xlUp)(2)
 
Last edited:

Watch MrExcel Video

Forum statistics

Threads
1,090,101
Messages
5,412,432
Members
403,427
Latest member
mese0115

This Week's Hot Topics

Top