cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Language Dependent Element in Workflow Container

Former Member
0 Likes
2,101

Hi Experts,

I have create a new workflow with a decision item for a certain step. This item has the following text:

As you can see it uses several Tokens as placeholders. While CONTRACT_ID and LICENSEE are just numbers PERIOD should be language dependent text. To achieve this I added attributed PERIOD in the global workflow container and filled it programatically when the workflow is started:

Methode "GET_PERIOD_TOKEN" delivers an identifiert like "APR", "NOV" etc.

Now I was looking for a user exit during the query/read process of workflows (e.g. when the item is shown in Tx. SBWP) to replace that identifiert by the correct language dependent text. Unfortunately I could not find any appropriate place to do that.

Is this approach correct? Is there even a solution for such an issue? Thanks in advance!

Regards

Tobias

View Entire Topic
Former Member
0 Likes

Hi Mike,

I tried the following. I created my own class implementing the IF_WORKFLOW interface and added it as an container element in the global container:

For testing purposes I added instance method "DO_SOMETHING" and static method "DO_SOMETHING_STATIC" to the class.

When I press F4 Valuehelp for Parameter 3 I can see my new class in the container but my methods are not listed. I just want to have a method that accepts the current value of Parameter "PERIOD" and translates this technical string to a language dependant human readable text. I guess it will be okay to use sy-langu for this since this expression for the workflow text is evaluated at runtime when a user opens the workflow inbox. So an english user would see the english text and a german user would see the german text.

You have any idea why my methods do not appear for my class in the value help?

Regards

Tobias

pokrakam
Active Contributor
0 Likes

Only attributes and methods called get_* are listed in the F4 help. get_<stuff> is a nearly universal (ABAP, Java, C,...) naming convention for methods that return a single value for <stuff>. In the WF object browser and F4 help, it actually strips the GET_ and shows the method name (in some versions anyway). So USER.GET_NAME( ) will show as USER.NAME in the object browser.

Static classes and methods won't show up, you would have to search through the entire ABAP class repository if it did! So just type it in as I showed above.

This will work in binding, and possibly for the task generation from your definition above. I don't know if it will stay dynamic once it lands in different users' inboxes, and don't have time to check, sorry.