Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]() Hi again, just googled around and discovered that the TextBoxes from the drawin Toolbar kann handle up to 32,767 Character in Excel 97 ... how com only 255 were saved to the array when I ran your code Peter ? Regards Ti -- TimBr ----------------------------------------------------------------------- TimBro's Profile: http://www.excelforum.com/member.php...fo&userid=1491 View this thread: http://www.excelforum.com/showthread.php?threadid=26541 |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
For some odd reason, with strings over 255 in (drawing)
textboxes you need to read or write in chunks of up to 255, something like this: Sub test3() Dim str1 As String, str2 As String, shp As Shape Dim j As Long, i as long 'manually create a textbox named "Text Box 3" Set shp = ActiveSheet.Shapes("Text Box 3") For j = 1 To 5 For i = 1 To 250 str1 = str1 & Chr(64 + j) Next str1 = str1 & vbLf & vbLf Next MsgBox Len(str1) With shp 'write j = 1 Do While j < Len(str1) s = Mid(str1, j, 250) .TextFrame.Characters(j).Insert String:=s j = j + 250 Loop MsgBox .TextFrame.Characters.Count 'read j = 1 Do While j < .TextFrame.Characters.Count str2 = str2 & .TextFrame.Characters(j, 250).Text j = j + 250 MsgBox Len(str2) Loop End With MsgBox Len(str2) Debug.Print str2 End Sub Regards, Peter -----Original Message----- Hi again, just googled around and discovered that the TextBoxes from the drawing Toolbar kann handle up to 32,767 Character in Excel 97 ... how come only 255 were saved to the array when I ran your code Peter ? Regards Tim -- TimBro ---------------------------------------------------------- -------------- TimBro's Profile: http://www.excelforum.com/member.php? action=getinfo&userid=14912 View this thread: http://www.excelforum.com/showthread...hreadid=265419 . |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Running mutiple excel sheets on mutiple computers | Excel Discussion (Misc queries) | |||
tab between several textboxes | Excel Worksheet Functions | |||
Accessing Mutiple TextBoxes | Excel Programming | |||
Accessing Mutiple TextBoxes | Excel Programming | |||
Textboxes | Excel Programming |