www.icetips.com  Icetips Utilities Documentation 7/6/2014    

String Class:  PadString

Previous  Top  Next  


Prototype: (String pStr, String pPad, Short pLen, Byte pStart=0),String

 

pStrString to pad
pPadPadding character or string to use
pLenLength of padded string
pStartOptional where to start the padding

 

ReturnsReturns the padded string

 

This method can be used to pad a string with character or repeated characters.  This can be useful when lining up strings with for example results of calculations when writing information to text files.

 

Example:

ITS  ITStringClass

S    String(1024)

Code

S = 'Test one'

S = ITS.PadString(S, '.',50) & '1'

! S should now be 'Test one.........................................1'

 



Direct link to this page: http://www.icetips.com/manuals/utilities/padstring_stringclass.htm