Hi everybody,
There are four different ways to store text in a Web Dynpro and FPM application.
You can read all about how to translate these texts in the following blog: ** TEAM FPM ** - All about Translation and Texts of FPM applications
But what about the choice of which way we should use to store the text.
In this blog I will describe my preferred choice in different scenario's. This is not a guideline from SAP, but it is my preferred way based on practical experience.
First of all you should always prefer to use a data element with the correct text.
Unfortunately this is not always possible.
There are four scenario's which I will describe below based on the difference that the text is static or dynamic and if you use the text for a Web Dynpro (freestyle) or for FPM.
Scenario 1: The text is static and is bound to an UI element in Web Dynpro
Preferred choice: You should store the text in the OTR (Online Text Repository)
Why: You can easily translate the text with function module: SOTR_API_WB_TRANSLATE
Scenario 2: The text is static, but not bound to an UI element in Web Dynpro
Preferred choice: You should store the text in the text element of a class
Why: If a text in the OTR is not bound to an UI element, then you can't easily translate it. For example you won't see the text in function module: SOTR_API_WB_TRANSLATE
Scenario 3: The text is static and used for FPM. This includes the FPM application (OIF, OVP, GAF) and also the GUIBBs
Preferred choice: You should store the text in the configuration.
Why: If you would use the OTR, then you don't see the text in administration or configuration mode, but you see the link to the OTR. That is not very user friendly.
Tip for FPM feeder class. In the method GET_DEFINITION set "label_by_ddic = abap_false" for table ET_FIELD_DESCRIPTION.
If you do this, then you will have the option to change the label in the configuration. Also if you leave the label empty in the configuration, then FPM will use the label of the data element.
Scenario 4: The text is dynamic and used in Web Dynpro or FPM
Preferred choice: You should store the text in the text element of a class
Why: The text is not bound to an UI element. You can't easily translate it when you use the OTR. For example you won't see the text in function module: SOTR_API_WB_TRANSLATE
Best regards,
Robin Vleeschhouwer
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Subject | Kudos |
---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
User | Count |
---|---|
4 | |
4 | |
4 | |
3 | |
3 | |
3 | |
3 | |
3 | |
3 | |
2 |