home *** CD-ROM | disk | FTP | other *** search
- ********************
-
- FUNCTION Centr
-
- PARAMETERS _temp, _therow, _thechar
-
- * _temp is the string passed to the function
- * _therow is the line length of the line
-
- PRIVATE _thecol, _atemp
-
- IF PCOUNT() = 1
- _therow = 80
- _thechar = CHR(32)
- ELSEIF PCOUNT() = 2
- _thechar = CHR(32)
- ENDIF
- IF TYPE("_temp")+TYPE("_therow")+TYPE("_thechar") != "CNC"
- RETURN("")
- ELSE
- _thecol = _therow / 2
- _atemp = _thecol - INT(LEN(_temp)/2)
- RETURN(REPLICATE(_thechar, _atemp) + _temp)
- ENDIF
-
- * End of File
-