Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Copy Entire Row
I need a line of code to copy an entire active row. I have a loop to find cells in A:A that meet a certain criteria. If that is met, I want to copy the entire active row to paste onto a different sheet. Thanks. -- scottnshelly ------------------------------------------------------------------------ scottnshelly's Profile: http://www.excelforum.com/member.php...fo&userid=7301 View this thread: http://www.excelforum.com/showthread...hreadid=551988 |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Copy Entire Row
ActiveCell.EntireRow.copy
-- Regards, Tom Ogilvy "scottnshelly" wrote: I need a line of code to copy an entire active row. I have a loop to find cells in A:A that meet a certain criteria. If that is met, I want to copy the entire active row to paste onto a different sheet. Thanks. -- scottnshelly ------------------------------------------------------------------------ scottnshelly's Profile: http://www.excelforum.com/member.php...fo&userid=7301 View this thread: http://www.excelforum.com/showthread...hreadid=551988 |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Copy Entire Row
Try using this, add a command button or autoshape button to run th code Regards, Simon Dim mycell Dim rng As Range t1 = InputBox("Enter the match you want", "What to look for?", "") Set rng = Range("A:A") For Each mycell In rng If mycell.Value = t1 Then mycell.Rows.Select Selection.Copy Sheets("Sheet2").Select Set rng = Worksheets("Sheet2").Cells(Rows.Count, 1).End(xlUp)(2) rng.Select ActiveSheet.Paste End If Next End Su -- Simon Lloy ----------------------------------------------------------------------- Simon Lloyd's Profile: http://www.excelforum.com/member.php...nfo&userid=670 View this thread: http://www.excelforum.com/showthread.php?threadid=55198 |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
Copy Entire Row
Thanks guys, Tom: I figured it'd be something simple like that. Thanks. Simon: Nothing happens after I push Enter on the input box. Thanks again -- scottnshell ----------------------------------------------------------------------- scottnshelly's Profile: http://www.excelforum.com/member.php...nfo&userid=730 View this thread: http://www.excelforum.com/showthread.php?threadid=55198 |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
to Copy the Entire Row | Excel Programming | |||
Copy entire row if.... | Excel Programming | |||
Copy entire row if... | Excel Programming | |||
how to copy entire row into next row | Excel Programming | |||
Code to copy range vs Copy Entire Worksheet - can't figure it out | Excel Programming |