Cell Charecter Limit

S

Soniya

Hi All,
By going thru this news group I find the maximum charecter limit for a
cell is 32768 and
only 1024 can be displayed.

I also noticed that when I try to print those charecters are not
printed too.

I am getting a textbox data to my cell A2. How cud I code to split the
data to A2 and A3 in case the charavcters are more than 1024?

Thanks
 
K

Kaak

j = 1
k = 1

For i =1 to Len(FormString)

Range("A" & k).value = Range("A" & k).value & Mid(FormString,i,1)


If j = 1024 Then

j = 0

k = k + 1

end if

j = j + 1

next i
 
J

JE McGimpsey

One way:

Dim i As Long
For i = 0 To Int((Len(sText) - 1) / 1024)
Range("A1").Offset(i, 0).Value = _
Mid(sText, (i) * 1024 + 1, 1024)
Next i
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top