cancel
Showing results for 
Search instead for 
Did you mean: 

FORM CHANGING at Unicode conversion

former_member210563
Participant
0 Kudos
79

Hi,

I have a form within a report like this:

*\FORM CALCULATE_TAX CHANGING I_BSEG-DMBTR.

FORM CALCULATE_TAX CHANGING I_BSEG.

*} REPLACE

  • End SIR PRD-A000368

DATA: I_FWNAV LIKE BSET-FWSTE,

I_FWNVV LIKE BSET-FWSTE,

I_FWSTE LIKE BSET-FWSTE,

I_FWAST LIKE BSET-FWSTE.

DATA: BEGIN OF I_MWDAT OCCURS 0.

INCLUDE STRUCTURE RTAX1U15.

DATA: END OF I_MWDAT.

CALL FUNCTION 'CALCULATE_TAX_FROM_NET_AMOUNT'

EXPORTING

I_BUKRS = I_TMP_ITEMS-BUKRS

  • Start SIR PRD-A000368

  • I_MWSKZ = BSEG-MWSKZ

I_MWSKZ = I_BSEG-MWSKZ

  • End SIR PRD-A000368

  • I_TXJCD = ' '

I_WAERS = I_TMP_ITEMS-WAERS

  • Start SIR PRD-A000368

  • I_WRBTR = BSEG-DMBTR

I_WRBTR = I_BSEG-DMBTR

  • End SIR PRD-A000368

  • I_ZBD1P = 0

I_PRSDT = I_TMP_ITEMS-BUDAT

IMPORTING

E_FWNAV = I_FWNAV

E_FWNVV = I_FWNVV

E_FWSTE = I_FWSTE

E_FWAST = I_FWAST

TABLES

T_MWDAT = I_MWDAT

EXCEPTIONS

BUKRS_NOT_FOUND = 1

COUNTRY_NOT_FOUND = 2

MWSKZ_NOT_DEFINED = 3

MWSKZ_NOT_VALID = 4

OTHERS = 5.

LOOP AT I_MWDAT.

  • BSEG-DMBTR = BSEG-DMBTR + I_MWDAT-WMWST.

I_BSEG-DMBTR = I_BSEG-DMBTR + I_MWDAT-WMWST.

  • End SIR PRD-A000368

ENDLOOP.

ENDFORM. " CALCULATE_TAX

In Unicode the "I_BSEG-DMBTR" in FORM CHANGING is no longer valid, but what to do then ?

Any help is appreciated.

Thanks.

Accepted Solutions (1)

Accepted Solutions (1)

uwe_schieferstein
Active Contributor
0 Kudos

Hello Peter

Unicode is (fortunately) much more restrict with regards to typing of formal parameters. The following code works perfectly fine on a UC-6.40 system.

*&---------------------------------------------------------------------*
*& Report  ZUS_SDN_UC_FORM_ROUTINE
*&
*&---------------------------------------------------------------------*
*&
*&
*&---------------------------------------------------------------------*

REPORT  zus_sdn_uc_form_routine.


TABLES: bseg.

DATA:
  gs_bseg  TYPE bseg.


START-OF-SELECTION.

  PERFORM calculate_tax
                 CHANGING
                       gs_bseg.

END-OF-SELECTION.


*&---------------------------------------------------------------------*
*&      Form  CALCULATE_TAX
*&---------------------------------------------------------------------*
*       text
*----------------------------------------------------------------------*
*      <--P_I_BSEG_DMBTR  text
*----------------------------------------------------------------------*
FORM calculate_tax
            CHANGING
                  i_bseg  TYPE bseg. " typing necessary !!!

...

Regards

Uwe

Answers (0)