Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5
Default Moving entire rows

Howdy,

First of all, I did search topics and attempt a solution listed before
posting, so I feel slightly vindicated, if not accomplished.

Within a macro, I'm comparing the values from 2 sheets. Among other things,
when equivalency is found, I'd lik to copy the entire row of the active cells
(all within the same row) to a third sheet.

I tried the following:

Worksheets("Third").Cells(Row variable, 1).EntireRow = Cells(Row
variable2,1).EntireRow.Copy

That didn't work, so I came here and searched for a solution that led me to
try:

Cells(Row variable2,1).EntireRow.Copy Destination :=
Worksheets("Third").EntireRow

Oddly enough, all I got from that attempt was, seemingly, the boolean result
of the equivalency test, as all cells in the destination row were filled with
"TRUE", but I've no real clue how that result was generated.

Any help would be greatly appreciated. Thanks a bunch.

Paul
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Moving entire rows


pvdalen,

Try something like this:


Cells(Row variable2,1).EntireRow.Copy Destination :=
Worksheets("Third").Range("A5")

Hope this gets you in the right direction.

Charle

--
Charle
-----------------------------------------------------------------------
Charles's Profile: http://www.excelforum.com/member.php...nfo&userid=601
View this thread: http://www.excelforum.com/showthread.php?threadid=27261

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5
Default Moving entire rows

Try this:
Cells(SourceRow, 1).EntireRow.Copy
Worksheets("Third").Cells(DestRow, 1).PasteSpecial xlPasteFormulas,
xlPasteSpecialOperationNone
If the result is not exactly what you intended, try changing xlPasteFormulas
to xlPasteValues or any of the other possible settings. You may want to
experiment a bit to see how each works.

HTH
Chris


"pvdalen" wrote in message
...
Howdy,

First of all, I did search topics and attempt a solution listed before
posting, so I feel slightly vindicated, if not accomplished.

Within a macro, I'm comparing the values from 2 sheets. Among other

things,
when equivalency is found, I'd lik to copy the entire row of the active

cells
(all within the same row) to a third sheet.

I tried the following:

Worksheets("Third").Cells(Row variable, 1).EntireRow = Cells(Row
variable2,1).EntireRow.Copy

That didn't work, so I came here and searched for a solution that led me

to
try:

Cells(Row variable2,1).EntireRow.Copy Destination :=
Worksheets("Third").EntireRow

Oddly enough, all I got from that attempt was, seemingly, the boolean

result
of the equivalency test, as all cells in the destination row were filled

with
"TRUE", but I've no real clue how that result was generated.

Any help would be greatly appreciated. Thanks a bunch.

Paul



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
finding and then moving entire row to new sheet based on cell value dave chamberlan Excel Discussion (Misc queries) 2 November 17th 09 01:27 AM
Moving data from multiple rows to single rows Pete Excel Worksheet Functions 5 February 16th 08 01:51 PM
Moving An Entire Row From One Sheet To Another M.A.Tyler Excel Discussion (Misc queries) 9 May 2nd 06 12:56 PM
Moving cursor to another cell w/out selecting entire area Darin Excel Discussion (Misc queries) 8 May 13th 05 08:44 PM
Entire worksheet moves when moving from cell to cell Al Excel Discussion (Misc queries) 3 April 21st 05 12:56 AM


All times are GMT +1. The time now is 09:41 AM.

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

About Us

"It's about Microsoft Excel"