Quantcast
Channel: SCN: Message List
Viewing all articles
Browse latest Browse all 8653

Problem in Field Symbol

$
0
0

Hi,

 

Please find below my code

 

   FIELD-SYMBOLS <lv_field> TYPE ANY.

 

 

      CLEAR lv_typ. DESCRIBE FIELD <lv_field> TYPE lv_typ.

      CASE lv_typ.

        WHEN 'C' OR 'D' OR 'N' OR 'T' OR 'G'.

          <lv_field> = ls_input-value.

          CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'

            EXPORTING

              input  = <lv_field>

            IMPORTING

              output = <lv_field>.

          ls_input-value = <lv_field>.

        WHEN 'P'.

          REPLACE ',' WITH '.' INTO ls_input-value.

          <lv_field> = ls_input-value.

        WHEN OTHERS.

      endcase,

 

     Here i have problem when <lv_field> has an Alpha Numeric value like

     Material No (ABC1234) , the statement DESCRIBE FIELD <lv_field> TYPE lv_typ.

     lv_typ gets the value 'P" and when it tries to move the value

        WHEN 'P'.

          REPLACE ',' WITH '.' INTO ls_input-value.

          <lv_field> = ls_input-value.

     it results in a Dump saying " Unable to interpret "ABC1234" as a number."

 

     How to overcome this.


Viewing all articles
Browse latest Browse all 8653

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>