ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Character Limitation (https://www.excelbanter.com/excel-discussion-misc-queries/83071-character-limitation.html)

hicksviv

Character Limitation
 

Hi,
I wonder if anyone can help. I have some cells that have lots of text
in - after around 1100 it seems to cut of the text. So ,if I do a row
'autofit' height it doesn't show all the text - however if I click the
fx button it shows it all - making sense?

I need to be able to print the file showing all the text - has anyone
got any idea how I can do this please?

Thanks in advance for any help!!

Viv


--
hicksviv
------------------------------------------------------------------------
hicksviv's Profile: http://www.excelforum.com/member.php...o&userid=33455
View this thread: http://www.excelforum.com/showthread...hreadid=532620


Dave Peterson

Character Limitation
 
If you pepper alt-enters (to force new lines within the cell) every 80-100
characters, you'll be able to see more characters.



hicksviv wrote:

Hi,
I wonder if anyone can help. I have some cells that have lots of text
in - after around 1100 it seems to cut of the text. So ,if I do a row
'autofit' height it doesn't show all the text - however if I click the
fx button it shows it all - making sense?

I need to be able to print the file showing all the text - has anyone
got any idea how I can do this please?

Thanks in advance for any help!!

Viv

--
hicksviv
------------------------------------------------------------------------
hicksviv's Profile: http://www.excelforum.com/member.php...o&userid=33455
View this thread: http://www.excelforum.com/showthread...hreadid=532620


--

Dave Peterson

hicksviv

Character Limitation
 

Thanks Dave - is there anyway to automate this? I have quite a few
cells with too much text!


--
hicksviv
------------------------------------------------------------------------
hicksviv's Profile: http://www.excelforum.com/member.php...o&userid=33455
View this thread: http://www.excelforum.com/showthread...hreadid=532620


Dave Peterson

Character Limitation
 
I guess you could look at the value in each cell and plop in those alt-enters.

I always wanted more control over where the line would break, though.

hicksviv wrote:

Thanks Dave - is there anyway to automate this? I have quite a few
cells with too much text!

--
hicksviv
------------------------------------------------------------------------
hicksviv's Profile: http://www.excelforum.com/member.php...o&userid=33455
View this thread: http://www.excelforum.com/showthread...hreadid=532620


--

Dave Peterson

Dave Peterson

Character Limitation
 
Try this against a copy (or close without saving)...

Option Explicit
Sub testme01()
Dim myRng As Range
Dim myCell As Range
Dim myStr As String
Dim iCtr As Long
Dim jCtr As Long

Set myRng = Selection

For Each myCell In myRng.Cells
If myCell.HasFormula Then
'skip it
Else
If Len(myCell.Value) 800 Then
myStr = myCell.Value
For iCtr = 80 To Len(myStr) Step 80
Do
jCtr = iCtr
If Mid(myStr, jCtr, 1) = " " Then
Mid(myStr, jCtr, 1) = vbLf
Exit Do
Else
jCtr = jCtr + 1
End If
Loop
Next iCtr
myCell.Value = myStr
End If

End If
Next myCell

End Sub

If you're new to macros, you may want to read David McRitchie's intro at:
http://www.mvps.org/dmcritchie/excel/getstarted.htm

Dave Peterson wrote:

I guess you could look at the value in each cell and plop in those alt-enters.

I always wanted more control over where the line would break, though.

hicksviv wrote:

Thanks Dave - is there anyway to automate this? I have quite a few
cells with too much text!

--
hicksviv
------------------------------------------------------------------------
hicksviv's Profile: http://www.excelforum.com/member.php...o&userid=33455
View this thread: http://www.excelforum.com/showthread...hreadid=532620


--

Dave Peterson


--

Dave Peterson


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

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com