cancel
Showing results for 
Search instead for 
Did you mean: 

How to change default locale determination in Adobe

Former Member
0 Kudos

Hi folks,

How to change default way of building locale in Adobe ? Right now, country and language from document params (passed to generated FM) are concatenated.

I've found also the place, where it happens: Function Module FPCOMP_FORM_START, form GET_LOCALE_FOR_DOCUMENT.

The problem is, when form is printed in English and all locale (e.g. date and number formatting) result in undesirable (and not existing!) definition, like en_PL.

So, the question is, if there's any way of controlling this process, like issuing an output in English but with locale pl_PL?

Thanks,

Radek

Accepted Solutions (1)

Accepted Solutions (1)

former_member531036
Participant
0 Kudos

Hi Radek,

If I'm understanding you correctly, you want to dynamically set the locale for the form. If so, you need to pass into the form a parameter containing the locale that you want the form set to. Then add the field to your form as a hidden field. Add the below JavaScript:

this.locale = xfa.resolveNode("data.V_LOCALE").rawValue;

Where "data" is the location of where field V_LOCALE exists. This only needs to be set once for the form in the ready.form routine.

Julie

Former Member
0 Kudos

Hi Julie,

Good idea, thanks

I've also entered this piece of code in the root node in hierarchy - "Data" and it's also working. Do you think ready.form is the good event for that ? Maybe initialize ?

Unfortunately, this solution requires to extend form interface each time, in order to access your additional document params and need to be scripted in each form separately. Maybe it would be good to append field to structure SFPDOCPARAMS (to access in all forms) w/o modifying interface each time, but that's just my digression.

Radek

former_member531036
Participant
0 Kudos

Hi Radek,

You could try initialize, but we've put this code in the ready.form and it works, so I figured....why try to break it.

We overhauled all of our forms last year because we were rolling out SAP to plants that required different formatting for numeric values and dates. So we implemented this as a form standard going forward.

Julie

Answers (0)