Hi
This follows on a bit from question ID 21389189 (but may not need to use it)
I have a string of "errors" which can get rather long.
If number of vbcrlf > 5 I want to trim the string - it has to be displayed on a messagebox so line upon line of vbcrlf is too big.
So, the string is called allErrors and I want to trim it after 5 vbcrlf, instead of displaying full string , allerrors should only display up to the 5th vbcrlf and end with "too many errors to display"
Using ID 21389189 code,
if CountChars(allErrors, vbcrlf) > 5 'this is how question ID 21389189 counts number of times a character appears
'delete the text after the 5th vbcrlf 'what goes here?
end if
Thanks for help
Start Free Trial