transfer entire row to another sheet

A

aditya

i want to apply following condition

IN SHEET1 if A2="ABC"
Transfer all data in row 2 to row 2 in sheet 2

pls help
 
D

Don Guillett

try
sub transferif()
if range("a2")="ABC" then rows(2).cut sheets("sheet2").range("a2")
end sub
 
E

Eduardo

Hi,
try
Sub copyrange()
'

With Sheets("Sheet1")
If Range("A2") = "ABC" Then
Rows(2).Copy


End If
End With



With Sheets("Sheet2").Range("A2")
.PasteSpecial xlPasteValues
.PasteSpecial xlPasteFormats
Application.CutCopyMode = False
End With

'
End Sub
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top