How to left pad a string with spaces

If this a structured text program, you could also take a look at the STANDARD library and the functions INSERT,LEN,MID,LEFT,RIGHT,DELETE and CONCAT.