cancel
Showing results for 
Search instead for 
Did you mean: 

How to change localized numbers in iGrid V11.5

Former Member
0 Kudos

Hi,

we use MII Version 11.5SR4 and I have a client which use a german localization on his PC.

When the user call an irpt page with an iGrid then this iGrid is displaying numbers for this german client allways with a comma for a decimal delimiter like this example 3,14159 (Pi).

I need to change this iGrid to display allways a dot and ignores the client settings for the decimal delimiter like this 3.14159.

The MII documentation has here something for localization but I did not find a solution which allows me to change this.

I tried with the NumberFormat Parameter e.g. <param name="NumberFormat" value="###.00" />,

but the result is allways the same for the german client, it displays the comma instead of the dot.

FYI: When I change the regional settings (Windows XP) for this client to english / us then it works as expected.

I hope there exists an parameter or way to initialize this applet to work allways as an english/us applet. e.g. like: this

<param name="Language" value="en" />

To change the query to display a customized string is not an option, because there is too much to change in the background.

Accepted Solutions (1)

Accepted Solutions (1)

jcgood25
Active Contributor
0 Kudos

Decompiling the java source code and rebundling your own version of the illum8.zip archive is of course not-supported (probably violates your license agreements too).

I'm confused - your client is configured for DE so the typical display for numbers would be #.##,00 but you want this to be the opposite #,##.00 ?

What is the normal situation? Is this just a specialized exception for certain columns in an iGrid on select pages?

Former Member
0 Kudos

Hi Jeremy,

the issue is that we have an application was build for the US area.

Now we migrate it to a site in EU and it's a special case, unfortunately we have to manipulate a lot of irpt, xsl, and Javascript files to fix it.

Maybe it would be a nice thing to have the flexibility to overwrite the applet parameter for numbers similar what we can do for the DateFormat parameter?

jcgood25
Active Contributor
0 Kudos

Specific to the iGrid is the ColumnFormats property (http://help.sap.com/saphelp_xmii115/helpdata/en/Applet_Reference_Details/iGrid_Reference.htm#iGrid Layout)

You may be encountering the fact that the NumberFormat parameter is common to both the underlying query template and the display template, so when you overload this in the html applet tags the grid has no way of knowing which template is applicable.

Try building a display template and provide the desired formats to the associated columns, etc. If you skip a column in the config table shown in the Template Editor it will revert to either the NumberFormat or DateFormat general tab setting, depending upon the datatype of the results.

Former Member
0 Kudos

Hi Jeremy,

Many thanks for your ideas.

I used a template but without any success.

I reviewed the igrid src and I think there is not possible to format the numbers as I like to have it.

Maybe something what SAP can implement for one of the next releases of MII if they like?

I'm not sure if you can address this to the right responsible

Many thanks to all for your help

jcgood25
Active Contributor
0 Kudos

I'm thinking that decompiling product source code might be a bit of s/w license violation, since unlike ABAP products the MII JAVA source code is not provided...

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi,

Call the query which is giving this kind of result in BLS transction.

And use this column values with available function and modify with your requirement.

Use this method :

stringreplace( String , search, replace )     ex:("3,14159", ",", ".")

Use Doc and Row action block to get the desired output and use Xacute query in your irpt page.

Hope this helps you.

-Suresh

Edited by: Suresh Hiremath on Jul 4, 2009 9:20 AM

Former Member
0 Kudos

Hi,

this is a really good idea!

Currently it's not not an option for me, because I have a lot of existing code / irpt pages which must be changed in this way, but maybe I have no other option...., but many thanks again.

I found in the meantime a way to manipulate the neccessary iGrid class in the way I need it. Unfortunately I have to replace some classes in illum8.zip archive where the igrid applet will be created.

The disadvantage here is that SAP will never support this customization...

With other words:

There exists no simple way to set the locale for the number format under MII V11.5

Former Member
0 Kudos

Hi Ottavio,

maybe in your scenario will help to change the Regional Settings on the client side. Inside the Regional Settings

you can choose the number format, but this means for the complete OS + other Software.

Regards

Pedro Iglesias

Former Member
0 Kudos

Hi Pedro,

yes that's also an option, but not possible for us, because the issue is that the are running a lot of other localized application in parallel which may confuse the users too.

One idea what we had was to start a little app before we start the MII app and this will change the Regional Settings to the english and later back to the german client, but as described before it make no sens for us.

The only simple solution would be to have an applet parameter like:

&lt;param name="LocalizedNumber" value="en" /&gt;

where we can overwrite the default number formatting.

But I did not found such or similar parameter under MII V11.5.

Do you know if this is what V12.x is supporting?

Former Member
0 Kudos

Ottavio,

I don't think so. I found nothing on 12.0, but maybe Jeremy can answer this. One option more is, when you return

your values as string and not as number. It is not the correct solution, but a workaround for you now.

Regards

Pedro

Former Member
0 Kudos

The underlaying query object is a SQL query and this is also a lot of work to change this there, but it's possible.