MUNDOSAP

Regresar   MUNDOSAP > DESARROLLO > Programación ABAP IV
Nombre de Usuario
Contraseña
Home Descargas Registrar FAQ Miembros Calendario Buscar Temas de Hoy Marcar Foros Como Leídos




 
 
 
Herramientas Buscar en Tema Desplegado
Prev Mensaje Previo   Próximo Mensaje Próx
  #1  
Viejo 26/11/08, 11:25:45
Sir_Kempis Sir_Kempis is offline
Junior Member
 
Fecha de Ingreso: nov 2007
Mensajes: 18
Post Problema con 'Asunto' de un Mail desde SAP

Hola a todos,

Estoy enviando un mail desde SAP a un correo externo con la función 'SO_DOCUMENT_SEND_API1' y el mail llega correctamente salvo por el ASUNTO del mail. Llega sin Asunto, Detallo el código por si alguien ve que puede estar fallando.


* Tabla con la estructura del mail
DATA: lt_packing_list TYPE STANDARD TABLE OF sopcklsti1 WITH HEADER LINE,

* Tabla con el cuerpo del mail
ut_contents_txt TYPE STANDARD TABLE OF solisti1 WITH HEADER LINE,

* Tabla con el Asunto del Mail
ut_asunto TYPE STANDARD TABLE OF solisti1 WITH HEADER LINE.

* Estructura con la cabecera del mail
lw_document_data TYPE sodocchgi1.


receptores-receiver = 'aaa@hotmail.com'.
receptores-rec_type = 'U'.
receptores-com_type = 'INT'. " ' '.
APPEND receptores.

* Ponemos el cuerpo del mail
ut_contents_txt-line = text-025.
APPEND ut_contents_txt.

* Ponemos el ASUNTO del mail
ut_asunto-line = text-029.
APPEND ut_asunto.


* Asigna la estructura del mail
lt_packing_list-doc_type = 'RAW'.
lt_packing_list-body_start = 1.
DESCRIBE TABLE ut_contents_txt LINES lt_packing_list-body_num.
lt_packing_list-head_start = 1.
DESCRIBE TABLE ut_asunto LINES lt_packing_list-head_num.

APPEND lt_packing_list.


* Envía mail
CALL FUNCTION 'SO_DOCUMENT_SEND_API1'
EXPORTING

document_data = lw_document_data
* put_in_outbox = 'X'
commit_work = 'X'
sender_address = emisor_smtp
sender_address_type = ' '
TABLES
packing_list = lt_packing_list[]
object_header = ut_asunto[]
contents_txt = ut_contents_txt[]
receivers = receptores[]
EXCEPTIONS
too_many_receivers = 1
document_not_sent = 2
document_type_not_exist = 3
operation_no_authorization = 4
parameter_error = 5
x_error = 6
enqueue_error = 7
OTHERS = 8.


Mirando los valores por DEBUG antes de llamar a la función:

lt_packing_list-head_start = 1
lt_packing_list-head_num = 1

UT_ASUNTO-LINE = Información Carga Tabla T9E12

No se que puede ser lo que falla

Muchas gracias.
Responder Con Cita
 


Herramientas Buscar en Tema
Buscar en Tema:

Búsqueda Avanzada
Desplegado

Reglas de Mensajes
no puedes crear nuevos temas
no puedes responder temas
no puedes adjuntar archivos
no puedes editar tus mensajes

El código vB está On
Las caritas están On
Código [IMG] está On
Código HTML está Off
Saltar a Foro


Husos Horarios son GMT. La hora en este momento es 08:15:43.


www.mundosap.com 2006 - Spain
software crm, crm on demand, software call center, crm act, crm solutions, crm gratis, crm web