Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 76
Default Macro Help - Copy Selected Row

Help_ I need to write a macro that will copy any single row that is
highlighted and paste it to a designated row on a different worksheet
Ex.~(Row50). I am reassembling a form based upon archived data in the row
being copied.

Please help!
~Thanks
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 11,058
Default Macro Help - Copy Selected Row

Sub TeddyB()
Selection.Copy Sheets("Sheet2").Range("A50")
End Sub

assuming you have select the entire row, it is a one-liner.
--
Gary''s Student - gsnu200750


"Teddy-B" wrote:

Help_ I need to write a macro that will copy any single row that is
highlighted and paste it to a designated row on a different worksheet
Ex.~(Row50). I am reassembling a form based upon archived data in the row
being copied.

Please help!
~Thanks

  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 638
Default Macro Help - Copy Selected Row

Sub foo()
Selection.EntireRow.Copy _
Destination:=Sheets("Sheet2").Rows(50)
End Sub

Teddy-B wrote:
Help_ I need to write a macro that will copy any single row that is
highlighted and paste it to a designated row on a different worksheet
Ex.~(Row50). I am reassembling a form based upon archived data in the row
being copied.

Please help!
~Thanks


  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 35,218
Default Macro Help - Copy Selected Row

One more...

Activecell.entirerow.copy _
destination:=worksheets("OtherSheetNameHere").rang e("A50")

Selection could be more than one row.

Teddy-B wrote:

Help_ I need to write a macro that will copy any single row that is
highlighted and paste it to a designated row on a different worksheet
Ex.~(Row50). I am reassembling a form based upon archived data in the row
being copied.

Please help!
~Thanks


--

Dave Peterson
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
excel: if selected, copy cell from corresponding row davey-in-the-navy Excel Worksheet Functions 1 October 7th 07 12:09 PM
Copy a selected number of rows Eric S. Excel Discussion (Misc queries) 4 June 25th 07 08:23 AM
Copy selected lines WTG Excel Worksheet Functions 9 February 17th 06 02:45 AM
Macro, Copy Selected Cells Down a Column DB33 Excel Discussion (Misc queries) 9 February 15th 06 09:29 PM
Copy Selected cells down a row with macro DB33 Excel Discussion (Misc queries) 1 February 15th 06 05:33 PM


All times are GMT +1. The time now is 09:52 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"