On Nov 5, 8:45 am, "Jameson" <rtgro...@hotmail.comwrote:
Hi,
Dumb question for you:
Is there a quick and easy way to ensure a string has a minimum width using
format specifier?
Should I just write
if myString.Length < 8 then myString.PadLeft ( ...... )
?
Thanks
In case you want to use string.format...
dim sMessage as string = string.format("{0,-8}", value)
If value is less then 8 characters, the result will be an 8 character
string left padded with spaces. To right pad, make the value after
the comma a positive number.
HTH
--
Tom Shelton