G
Geoff
Is it possible to create a formula longer than 255 characters? At this point
you get an error.
you get an error.
Dave Peterson said:I bet that Niek meant for you to write your function so that it does the
concatenating--not passing the long string to it:
Option Explicit
Function CustomNew(ParamArray Args() As Variant) As Long
Dim myLongString
Dim iCtr As Long
myLongString = ""
For iCtr = LBound(Args) To UBound(Args)
myLongString = myLongString & Args(iCtr)
Next iCtr
CustomNew = Len(myLongString)
End Function
I got 502 back when I did this:
=CustomNew("y","n",REPT("aaaaa",50),REPT("aaaaa",50))
Geoff said:Thanks
This will work
textDave Peterson said:I bet that Niek meant for you to write your function so that it does the
concatenating--not passing the long string to it:
Option Explicit
Function CustomNew(ParamArray Args() As Variant) As Long
Dim myLongString
Dim iCtr As Long
myLongString = ""
For iCtr = LBound(Args) To UBound(Args)
myLongString = myLongString & Args(iCtr)
Next iCtr
CustomNew = Len(myLongString)
End Function
I got 502 back when I did this:
=CustomNew("y","n",REPT("aaaaa",50),REPT("aaaaa",50))=UPPER("aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"&"aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"&"aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa so
Niek said:Thanks Dave!
--
Kind Regards,
Niek Otten
Microsoft MVP - Excel