Skip to Content
0
Former Member
Feb 07, 2011 at 05:55 AM

ASSIGN_CASTING_ILLEGAL_CAST for FM 'F4IF_INT_TABLE_VALUE_REQUEST'

287 Views

Hi,

I'm using FM 'F4IF_INT_TABLE_VALUE_REQUEST' to get f4 help on selection screen.

When i do a select query,and assign the value to the VALUE_TAB parameter in the FM there is a short dump ASSIGN_CASTING_ILLEGAL_CAST (Exception CX_SY_ASSIGN_CAST_ILLEGAL_CAST ) .

Below is the code that i have implemented. Please do let me know how i can get this working?


AT SELECTION-SCREEN ON VALUE-REQUEST FOR s_delmet-low.


SELECT TFORMP FROM LSOTFORMP_C INTO TABLE t_tformp
                             WHERE schedule_dep = 'X'.

  SELECT tform FROM LSOTFORM_C INTO TABLE t_tform
                             FOR ALL ENTRIES IN t_tformp
                             WHERE TFORMP = t_tformp-tformp.

  SELECT TFORM TXTSHORT FROM LSOTFORMT_C INTO TABLE T_TFORMtxt
                             FOR ALL ENTRIES IN T_TFORM
                            WHERE TFORM = T_TFORM-T_FORM AND
                                  SPRAS  = sy-langu.

    CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
    EXPORTING
      retfield        = 'S_DELMET-LOW'
      DYNPPROG        = SY-REPID
      DYNPNR          = SY-DYNNR
      DYNPROFIELD     = 'S_DELMET-LOW'
      value_org       = 'S'
    TABLES
      value_tab       = t_tformtxt
      return_tab      = t_return1
    EXCEPTIONS
      parameter_error = 1
      no_values_found = 2
      OTHERS          = 3.