LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 40
Default copy/paste: strange feature (I think)

I just found that the result of a horizontal Paste can take 2 forms depending
on the relation of the number of copied columns to the number of columns in
the destination range:
€¢ If the number of destination columns eg 16384 is divisible without
remainder by the number of copied columns eg 32 (result = 512) then the
copied columns will be pasted 512 times next to each other, covering the
whole destination range.
€¢ Otherwise they will be pasted only exactly once padded with empty cells at
the right.

Being a coding novice I created below piece of code with the intention to
paste the copied range only once but it does it 512 times. How can I improve
my code?
Sheets("Sheet1").Range("A10:AF10").Copy
Sheets("Sheet2").Rows(1).PasteSpecial (xlPasteValues)

 
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
Find Feature and Paste Link Erika Excel Discussion (Misc queries) 5 September 18th 08 08:24 PM
Using Paste Feature with out Activating Sheet watchtower Excel Programming 6 August 29th 07 08:06 PM
Strange Copy/Paste behavior Ray Excel Discussion (Misc queries) 3 July 9th 07 03:27 PM
Copy/paste from Win SQL gives strange characters Lars Excel Discussion (Misc queries) 0 May 29th 07 08:05 AM
Strange copy & paste behavior Doug Kanter Excel Discussion (Misc queries) 1 April 20th 06 12:35 AM


All times are GMT +1. The time now is 11:31 PM.

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"