Hi,
I'm building data bound control using the SDK.
I have the requirement to format numbers, and for that I'm using the format function of sap.common.globalization.NumericFormatManager which is part of the CVOM library.
Positive values are formatted well, so - for example - the number 268.32302514493136 becomes "268,32" - thats good.
Negatives values are formatted this way: 268.32302514493136 becomes "'-'268,32" - with the minus sign encapsulated in single quites - thats bad.
The format function expects 2 parametes, the value and the format string.
I get the format string from the data source of the dimension in the property formatString:
var formatStr = data.dimensions[0].members[tuple[0]].formatString;
The format string looks likes this:
"#.##0,00;'-'#.##0,00"
and I guess thats the problem - the format string self contains the minus sign quoted in strings.
The question is: Why? And how can I change this format string?
Of course I could easily solve this and remove the quotes in my javascript coding on component level, but that's more a workaround then a solution, and I want to know whats going on there ![]()
Many thanks,
ben