Autor Tema: Dump al hacer un CALL FUNCTION en background URGENTE  (Leído 7858 veces)

0 Usuarios y 1 Visitante están viendo este tema.

Desconectado raulgar

  • Novato
  • *
  • Mensajes: 3
    • Ver Perfil
Dump al hacer un CALL FUNCTION en background URGENTE
« en: 04 de Septiembre de 2008, 02:27:36 pm »
Hola a todos.

Necesito ayuda. El problema que tengo es que me da un dump cuando hago una llamada a una función en background. Necesito que sea en back porque tiene que esperar a que se desbloqueen unos objetos para que haga un BI.

Esta es la llamada.
CALL FUNCTION 'ZREVALORIZACION_MATERIALES' IN BACKGROUND TASK
* CALL FUNCTION 'ZREVALORIZACION_MATERIALES' IN UPDATE TASK
EXPORTING
w_mseg = w_mseg.

Tengo comentado todo lo que hace dentro de la función y me da un dump por lo que el error es en la llamada. Os copio el dump en cuestión.

Errores tiempo ejec. PERFORM_PARAMETER_MISSING
Excepción CX_SY_DYN_CALL_PARAM_MISSING
Fecha y hora 04.09.2008 14:12:44

¿Qué ha sucedido?
A routine call specifies fewer parameters than the number
given when defining the routine.

Anál.errores
An exception occurred that is explained in detail below.
The exception, which is assigned to class 'CX_SY_DYN_CALL_PARAM_MISSING', was
not caught in
procedure "XAB_RUN_DRIVER" "(FORM)", nor was it propagated by a RAISING clause.
Since the caller of the procedure could not have anticipated that the
exception would occur, the current program is terminated.
The reason for the exception is:
A PERFORM was used to call the routine "XAB_RUN_DRIVER" of the program
"SAPMSSY1".
The current call contains 0 actual parameter(s),
but the routine "XAB_RUN_DRIVER" expects more than 0 parameters.
parameters.

Codigo


data : subrc type i.

call 'AB_GET_C_PARMS' id 'P1' field <prog> "Programmname
id 'P2' field <cntl>. "Handle

perform rfcdrv_rflush in program (<prog>) using <cntl>
subrc
if found.

call 'AB_SET_C_PARMS' id 'P2' field <cntl>. "Handle
syst-subrc = subrc.
endform.

form xab_run_driver using prog type c
if_found type i
new_function type c.
data : program like syst-repid.

program = prog.
if new_function = space.
call 'RfcImport' id 'Push' field rfctype_abap4_exit
id 'Info' field program.
else.
call 'RfcImport' id 'Push' field rfctype_abap4_exit
id 'Info' field program
id 'Function' field new_function.
endif.
if if_found = 0.
perform (sy-xform) in program (sy-xprog).
else. FALLO AQUI
perform (sy-xform) in program (sy-xprog) if found.
endif.

endform.

Alguien sabe que puede ser???

Muchas gracias!

Desconectado raulgar

  • Novato
  • *
  • Mensajes: 3
    • Ver Perfil
Re: Dump al hacer un CALL FUNCTION en background URGENTE
« Respuesta #1 en: 04 de Septiembre de 2008, 02:43:48 pm »
Se me olvidaba comentar que la llamada a la funcion es dentro de una BADI. En concreto la ZMB_MIGO_BADI en la interfase IF_EX_MB_MIGO_BADI~POST_DOCUMENT.

Muchas gracias.

Desconectado molaci

  • Usuario Sr.
  • ****
  • Mensajes: 113
    • Ver Perfil
Re: Dump al hacer un CALL FUNCTION en background URGENTE
« Respuesta #2 en: 04 de Septiembre de 2008, 03:45:56 pm »
Puede ser porque le estas pasando unos parámetros a la función que no están declarados de la misma forma que los parámetros de entrada.