LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #5   Report Post  
David McRitchie
 
Posts: n/a
Default Maximum number of characters in a cell

In VBA you want to use vbLf as it is only CHR(10)
which is Line Feed that Excel will pay attention to,
and you will have to turn on cell wrapping in your code,
or in the formatting for the column.

In Excel for a text constant. The can use of Alt+Enter is what
will extend the display. It will also turn on cell wrapping.
Not documented in the specifications that you can increase
the number of characters displayed by doing this. You can
use CHAR(10) in a worksheet formula concatenation.

In a Worksheet Formula you would also be limited to:
Length of formula contents 1,024 characters

In your Excel help look up "specification"
---
HTH,
David McRitchie, Microsoft MVP - Excel [site changed Nov. 2001]
My Excel Pages: http://www.mvps.org/dmcritchie/excel/excel.htm
Search Page: http://www.mvps.org/dmcritchie/excel/search.htm

"Bill Murphy" wrote in message ...
RD,

I'm having trouble inserting a manual line break in my text, so I must have
a syntax problem. I'm doing this in a function named fConcatChild, and
returning the results to a query which is then exported to Excel using Excel
automation from within Access. Here's the code in my function:

' insert a hard return for display in Excel if the string is longer than
255
If Len(fConcatChild) 255 Then
fConcatChild = Left(fConcatChild, 255) & vbCrLf &
Right(fConcatChild, Len(fConcatChild) - 255)

End If

I'm still getting only about 255 characters in the cell in Excel to which
this variable is exported. Am I using the wrong Visual Basic constant
vbCrLf?

Bill

"Ragdyer" wrote in message
...
If you would add some forced (manual) line breaks (<Alt <Enter) in your
text at opportune locations, you will find that you can *display* much

more
text.
--
HTH,

RD

--------------------------------------------------------------------------

-
Please keep all correspondence within the NewsGroup, so all may benefit !
--------------------------------------------------------------------------

-
"Bill Murphy" wrote in message
...
Is there a way to format a cell so that it can contain more than 255
characters?

Bill









 
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
Number of characters in a cell (one row, merged columns) Dajana Excel Discussion (Misc queries) 1 September 19th 05 09:30 PM
fill or truncate to a certain number of characters in a cell Jan Buckley Excel Worksheet Functions 1 March 16th 05 03:46 PM
How do you count number of characters in a single cell Joe Excel Worksheet Functions 1 February 18th 05 09:08 PM
How do you count number of characters in a single cell Joe Excel Worksheet Functions 1 February 18th 05 08:33 PM
Defining a number in a cell by text then subtracting it by the tex Crowraine Excel Worksheet Functions 1 December 16th 04 07:49 AM


All times are GMT +1. The time now is 04:15 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"