Skip to Content

Languages in perform

Hello,

I have worked on date indicator with using perform, I thought of improve it by using the ‘EN’ language entry in the perform for all the formatting needs and only use the native language entry for the text.This will avoid issue if a customer only partially translated some fields. This way at least the EN language value would be used as default.

I am bit confused about using 'EN' in PERFORM (FORM) and I haven`t worked on that.

So any idea of how to make this work in better way?

Regards,

EH

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

4 Answers

  • Dec 23, 2014 at 07:40 AM

    Hi,

    sy-langu is the one which holds system language. You can refer this.

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Dec 23, 2014 at 07:42 AM

    Hi Ethan,

    Your question is not clear. What you need to improve using language?

    Are you talking about reports or smartforms? What exactly you are trying to achieve?

    Add comment
    10|10000 characters needed characters exceeded

  • Dec 23, 2014 at 08:10 AM

    Hi Ethan,

    You can check for sy-langu initially and if it is 'E' set a flag.

    Use this flag in perform.

    This is what I understand from your requirement. if not do let me know.

    Hope this helps.

    Rgds,

    K.S

    Add comment
    10|10000 characters needed characters exceeded

  • Dec 23, 2014 at 09:29 AM

    Hi all,

    Sorry for late reply.. Got stuck in other implementation 🤣

    Well, its seems to be silly, but I couldn`t push further of my thinking for the new improvement.

    Here is the subroutine.

    FORM build_lst_table_dats USING  p_len     TYPE any

                                       p_stxt    TYPE any

                                       p_fnam    TYPE any

                                       "p_curr    TYPE any

                                       p_hotspot TYPE any.

       DATA: lst_tab LIKE field_cat.

       DESCRIBE TABLE field_lst LINES sy-tfill.

       IF sy-tfill = 0.

         field_pos = 1.

       ELSE.

         ADD 1 TO field_pos.

       ENDIF.

       lst_tab-outputlen = p_len.

       lst_tab-col_pos   = field_pos.

       lst_tab-coltext = p_stxt.

       lst_tab-hotspot   = p_hotspot.

       lst_tab-fieldname = p_fnam.

    *  lst_tab-cfieldname = p_curr.

       lst_tab-datatype = 'DATS'.

    *  lst_tab-just      = 'R'.

       IF field_pos = 1 OR field_pos = 2.

         lst_tab-fix_column = 'X'.

       ENDIF.

       APPEND lst_tab TO field_lst.

    ENDFORM.

    Here I thought of providing all formatting IF the language is ENGLISH.... and Native language(sy-langu) for entry of the TEXT.

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member

      Hi Ethan Hunt


      The text passed in perform routine is Text-symbols ??


      like below


      perform build_lst_table_dats USING  P_LEN    TYPE any

                                                                      Text-c01 TYPE any

                                         p_fnam    TYPE any

                                         "p_curr    TYPE any

                                         p_hotspot TYPE any.