Moving rows to a couple of different sheets based on the value

Jimmytheman

New Member
Joined
Jan 10, 2017
Messages
2
Hey Guys,

I have to make a sort of database to make my job a little bit easier and have been struggling with macro's.(I'm a big excel noob) What I would like to make is a macro that scans the column (categorie) for the inserted value (one of the 4) and based on that value moves the entire row to another worksheet.
Sorry for the Language, I need it to work in Dutch.
It won't let me upload an image of the table so I included a dropbox link with a screenshot.
https://www.dropbox.com/s/dirrii65o1rz21l/Screen Shot 2017-01-10 at 14.02.03.png?dl=0

The values are in column G
Categorie/worksheet
Expert->Experts
Champion->Champions
Sleutelfiguur->Sleutelfiguren
Nieuw contact-Nieuwe contacten

I appreciate your help! Thank you so much.




VoornaamAchternaamFaculteit/dienstspecialiteitEmailLaatst gesprokenCategorie
JohnAppleFERExcel.10/10/10Expert

<tbody>
</tbody>
 

Excel Facts

When they said...
When they said you are going to "Excel at life", they meant you "will be doing Excel your whole life".
I'm trying to make this work as a simple start of the code but I'm not sure what im doing.

Sub copyrows()


Dim tfCol As Range, Cell As Object



Set Experts = Sheet1
Set Champions = Sheet2
Set Sleutelfiguren = Sheet3
Set Nieuwecontacten = Sheet4


Set tfCol = Range("'Alle Contacten'!G:G")
For Each Cell In tfCol
If IsEmpty(Cell) Then
Exit Sub


If Cell.Value = “Expert” Then
Cell.EntireRow.Copy
Sheet1.Select
ActiveSheet.Range("A65536").End(xlUp).Select
Selection.Offset(1, 0).Select
ActiveSheet.Paste
End Sub
 
Upvote 0

Forum statistics

Threads
1,215,040
Messages
6,122,806
Members
449,095
Latest member
m_smith_solihull

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top