Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

use of functoin 'RS_CONV_EX_2_IN'

Former Member
0 Kudos
413

HI

I am using the FM 'RS_CONV_EX_2_IN' to convert external format to internal and when i enter as input field

P2002-BEGUZ i face dump ,the fileld is time field from pa30/20 time field. TYPE T(6)

the dump is invalid_fieldname = 15 ,

For other field of time its working . like XUMODTIME from transcation su01

So how can i overcome these issue ?

Regards

Alex

1 ACCEPTED SOLUTION

Former Member
0 Kudos
148

Read your FM documentation, input has to be type C....the code below returns sy-subrc = 0 and lv_time2 = 151515...

DATA: lv_time(8) TYPE c,
       lv_time2 TYPE t,
      ls_tab TYPE tabfield.
lv_time = '15:15:15'.
ls_tab-tabname = 'P2002'.
ls_tab-fieldname = 'BEGUZ'.
CALL FUNCTION 'RS_CONV_EX_2_IN'
  EXPORTING
    input_external                     = lv_time
    table_field                        = ls_tab
*   CURRENCY                           =
 IMPORTING
   output_internal                    = lv_time2
 EXCEPTIONS
   input_not_numerical                = 1
   ...... (all exceptions)....
write sy-subrc.
write lv_time2.

1 REPLY 1

Former Member
0 Kudos
149

Read your FM documentation, input has to be type C....the code below returns sy-subrc = 0 and lv_time2 = 151515...

DATA: lv_time(8) TYPE c,
       lv_time2 TYPE t,
      ls_tab TYPE tabfield.
lv_time = '15:15:15'.
ls_tab-tabname = 'P2002'.
ls_tab-fieldname = 'BEGUZ'.
CALL FUNCTION 'RS_CONV_EX_2_IN'
  EXPORTING
    input_external                     = lv_time
    table_field                        = ls_tab
*   CURRENCY                           =
 IMPORTING
   output_internal                    = lv_time2
 EXCEPTIONS
   input_not_numerical                = 1
   ...... (all exceptions)....
write sy-subrc.
write lv_time2.