on 07-17-2015 8:47 AM
Hi guys,
For a few weeks now I've been meddling with the offline store and it's capabilities thanks to "".
I've succeeded opening, refreshing, closing the store. Now that I've read the data and saved it to the store, I'm trying to use it.
I have an issue with it.
Ex: As you can see on the right side, the values is correct 1323,39 / 2500,00 RON (credit usage, and credit limit) when I read them directly from the back-end.
But when I read them from the offline store, the value changes. I have 2.5e+3 instead of 2500.00 RON.
While debugging the request to and from the back-end system, I haven't seen a change in the value.
The view it's XMLView and the value is written like this:
number="{Clients>CreditUsage} / {Clients>CreditLimit}"
so no formats.
Do you guys have a clue why this happens ?
Thank you in advance,
Marius
Hi,
I remember I faced this issue long back while developing app on android. As a workaround I used type casting of values before showing it in screen. You could try it like .toString();
Regards,Midhun
SAP Technology RIG
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Midhun,
"long back" ?
I used a formatter and now the value looks similar to the one done from back-end.
CreditUsage = parseFloat(CreditUsage);
CreditLimit = parseFloat(CreditLimit);
return ( oNumberFormatD2.format(CreditUsage) + " / " + oNumberFormatD2.format(CreditLimit) );
where "oNumberFormatD2" is :
jQuery.sap.require("sap.ui.core.format.NumberFormat");
oNumberFormatD2 = sap.ui.core.format.NumberFormat.getIntegerInstance({
maxFractionDigits: 2,
minFractionDigits: 2,
groupingEnabled: false });
What i'm afraid of is loosing value. For example: 1234567,89 RON to be ransformed in 1,2e+6 ... and when I format it back I get 1200000.00 RON. I'll have to check it out.
Basically is something like you described.
Thanks,
Marius
User | Count |
---|---|
88 | |
10 | |
10 | |
9 | |
7 | |
7 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.