Copy/Paste if cell equals a word

steven426

New Member
Joined
Jul 13, 2009
Messages
19
Hi:

I am trying to figure out how to go down a list of words and copy/paste a row if it equals a specific ring of words. For example, if want to go down a column and copy the word "Dog" if the word is "Dog" and paste it to the second sheet in a certain column... The thing that I can't figure out is how to step down to the next row until the cell is empty...

I tried the code below, which is nowhere close to working... thanks

Sub Cats_and_Dogs()
For i = 1 To 100
If Range("i, 1") = "Dog" Then
Range("i,1").Select
Selection.Copy
Sheet2.Paste
End If
Next
End Sub
 
I guess I could explain a bit more:
I got a column of non and numeric values and want to copy numeric to the same row in next column. If its not numeric than i want to copy the last numeric value. so need a help with the part below:
else IsNumeric(Cell.Value) = False Then ... (eg copy here the cell above)
thanks
 
Upvote 0

Excel Facts

Formula for Yesterday
Name Manager, New Name. Yesterday =TODAY()-1. OK. Then, use =YESTERDAY in any cell. Tomorrow could be =TODAY()+1.

Forum statistics

Threads
1,216,822
Messages
6,132,913
Members
449,768
Latest member
LouBa

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