SAP ABAP验证数字合法性

同理,验证数字:

DATA:  v_int TYPE i,
             v_c(8) TYPE c.

****************************
* check number
****************************
v_c = 'A'.
TRY.
    v_int = v_c.
    WRITE: / v_c , ' is a OK number.'.
  CATCH CX_ROOT. "all error
    WRITE: / v_c ,' is a Wrong number!'.
ENDTRY. 

你可能感兴趣的:(c,SAP)