Thread: 255 truncation
View Single Post
  #4   Report Post  
Posted to microsoft.public.excel.misc
GS[_2_] GS[_2_] is offline
external usenet poster
 
Posts: 3,514
Default 255 truncation

Ron Rosenfeld formulated the question :
On Fri, 18 May 2012 13:03:36 -0400, GS wrote:

By default, Excel's limit for copy/paste operations is 255 characters.
To work around this I usually enter EditMode (F2) to paste data copied
from web pages (or any other content containing html/php). Sometimes,
I'll paste in Notepad first, then edit as required, then copy/paste to
a cell AFTER entering EditMode.

Any sheets being copied also lose any characters beyond the 255 limit.


I believe there is something different going on, because there seems to be a
great deal of variability in the results of copy/paste operations when the
source is a web page. There's clearly something I am not understanding.

If I navigate to that page using FireFox, select "all", then copy/paste into
Excel, everything gets pasted in: although as text all on one line; but it is
almost 6000 characters. If I try this from IE9, I get a one line string of
521 characters. However, if I paste into a single cell, I get a string of
5555 characters. If I "view source" in IE, and select all/copy/paste into
Excel, I get 118 lines with 6216 characters. If I do the same but paste it
into a single cell in Excel, I see a string with 6388 characters.


Now that's interesting! My experience with copying data from a web page
is rather limited, being mostly manually grabbing 'tabled/delimited'
data which 'usually' parses into rows/cols outside EditMode. Everything
else gets handled as I described, otherwise, unless dumping the data
into an array to be further processed before writing to a worksheet.

However.., I've never experienced a copy/paste process than carries
over more than 255 chars from cells. I suspect the issue here is how
the data gets into the cells, and so is why I shared my 'intermediate
step' workaround (which usually doesn't give me any surprise
results).<g

--
Garry

Free usenet access at http://www.eternal-september.org
ClassicVB Users Regroup!
comp.lang.basic.visual.misc
microsoft.public.vb.general.discussion