I need to produce fixed length string to generate a character position based file. The missing characters must be filled with space character.
As an example, the fi
public static String padString(String word, int length) { String newWord = word; for(int count = word.length(); count < length; count++) { newWord = " " + newWord; } return newWord; }