KB Article #182799

PadString function not adding spaces?

Problem

-- If you are using the function PadString right or left:


Reason := PadStringRight("Test",10) + "." + PadStringRight("Test1",10)


and if you are wondering why when you open the output file (the xml file) using the browser the output is like this:


<Reason>Test .Test1 </Reason>

Resolution

* This is a default behaviour of most browsers, if you want to see real content of the xml file you will need to open the file using an text editor and then you will see the added spaces

* so the PadStringRight is working properly and add the 6 spaces for the first (Test) string and 5 spaces for the second one.