'The inline-declared variable is not recognized

I am having a problem where the system does not recognize a local variable that I have declared. The code is as follows:

DATA(lv_dmbtr) = ZSD_LGS-DMBTR.

  IF ( lv_dmbtr MOD 10000000 ) LE 9.
    lv_dmbtr / 10000000 = lv_tenmillions.      //Error line
    lv_tenmillions_check = lv_tenmillions MOD 1.

    IF lv_tenmillions_check > 0.
     "Convert
   ENDIF.

   IF lv_tenmillions_check < 0.
     "ZERO
   ENDIF.
  ENDIF.

The program gives me an error in the line that I have input in the program, where it says "There is no LV_DMBTR statement. Please check the spelling."

May anyone of you know where the problem may be?

Thank you all in advance!



Solution 1:[1]

Try this:

DATA(lv_dmbtr) = ZSD_LGS-DMBTR.
lv_dmbtr  = ZSD_LGS-DMBTR MOD 10000000
  IF lv_dmbtr MOD 10000000 LE 9.
    lv_dmbtr / 10000000 = lv_tenmillions.      //Error line
    lv_tenmillions_check = lv_tenmillions MOD 1.

    IF lv_tenmillions_check > 0.
     "Convert
   ENDIF.

   IF lv_tenmillions_check < 0.
     "ZERO
   ENDIF.
  ENDIF.

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 MrSamael