strPrompt Function
Appends to a string the specified number of period characters followed by a colon and space character.
str strPrompt(str _string, _int len)
In atypical cases where the value of the _len parameter is only slightly larger than the length of the original string, top precedence is given to adding the trailing space. The next precedence is given to the colon. The lowest precedence is given to the periods. Negative values for the _len parameter return the input string appended with a trailing space.
-
strPrompt(“ab”,-1); //Returns “ab “.
-
strPrompt(“ab”,3); //Returns “ab “.
-
strPrompt(“ab”,4); //Returns “ab: “.
-
strPrompt(“ab”,5); //Returns “ab.: “.
-
strPrompt(“ab”,6); //Returns “ab..: “.