MUNDOSAP

MUNDOSAP (foro/index.php)
-   Programación ABAP IV (foro/forumdisplay.php?f=4)
-   -   Salto del Línea en un TXT (foro/showthread.php?t=36407)

karvi 26/04/10 15:56:00

Salto del Línea en un TXT
 
Buenas, quiero adjuntar un txt a un email. El txt lo genero en el momento de enviar el mail, simplemente tomo el objbin y le agrego lineas para generar el txt. El problema es que me genera una sola linea, en lugar de una linea por cada carga. Necesito saber como ponerle un salto de linea a cada linea que cargo.

Muchas gracias!

mysmb2 26/04/10 17:22:25

buenas,
podrias decirnos que funcion estas usando.

Saludos.

karvi 26/04/10 17:51:20

Hola, estoy usando la siguiente funcion:
CALL FUNCTION 'SO_NEW_DOCUMENT_ATT_SEND_API1'
EXPORTING
document_data = doc_chng
put_in_outbox = 'X'
commit_work = 'X'
TABLES
packing_list = objpack
object_header = objhead
contents_bin = objbin
contents_txt = objtxt
receivers = reclist
EXCEPTIONS
too_many_receivers = 1
document_not_sent = 2
operation_no_authorization = 4
OTHERS = 99.

Donde objbin es la tabla que lleva el txt adjunto, y es de tipo solisti1

valequique 27/09/10 22:26:06

Hola que tal, tengo el mismo problema que tu y los textos me los esta separando por espacios ¿encontraste alguna solucion?

Saludos.

francesc 28/09/10 07:28:38

Hola debes informar también la tabla packing_list. Es aquí donde se informa entre otras cosas del nº de líneas del documento anexo ( campo packing_list-body_num ), el tipo de fichero anexado (excel, txt, etc..). Adjunto un ejemplo donde se anexa un .XLS:

* Cuerpo del mensaje
CLEAR t_packing_list.
REFRESH t_packing_list.
t_packing_list-transf_bin = space.
t_packing_list-head_start = 1.
t_packing_list-head_num = 0.
t_packing_list-body_start = 1.
DESCRIBE TABLE it_mess_att LINES t_packing_list-body_num.
* it_mess_att es la tabla con la información anexada
t_packing_list-doc_type = 'RAW'.
APPEND t_packing_list.
* Notificación de anexo
t_packing_list-transf_bin = 'X'.
t_packing_list-head_start = 1.
t_packing_list-head_num = 1.
t_packing_list-body_start = 1.
DESCRIBE TABLE t_attachment LINES t_packing_list-body_num.
t_packing_list-doc_type = 'XLS'. "Tipo de fichero
t_packing_list-obj_descr = 'Inventario y consumos'. "Título
t_packing_list-doc_size = t_packing_list-body_num * 255.
APPEND t_packing_list.


Husos Horarios son GMT. La hora en este momento es 19:53:29.

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