Se puede hacer con: SO_NEW_DOCUMENT_SEND_API1
Pero limita el Asunto a 12 caracteres y el Cuerpo del email a 50.
He encontrado éste código, pero no se como anexar la tabla interna en la q tengo el PDF, si alguien me podría echar una mano por favor.
DATA : l_o_send_request TYPE REF TO cl_bcs, " email request object
l_o_document TYPE REF TO cl_document_bcs, " documents object
l_o_sender TYPE REF TO cl_cam_address_bcs, " sender object
l_o_recipient TYPE REF TO cl_cam_address_bcs, " recipient object
bcs_exception TYPE REF TO cx_bcs, " exceptions
l_v_ret TYPE os_boolean, " boolean return value
" document contents
l_it_contents TYPE bcsy_text,
l_wa_contents TYPE LINE OF bcsy_text,
" documents attachment
l_i_attachment TYPE solix_tab.
TRY.
" create email objects
l_o_send_request = cl_bcs=>create_persistent( ).
" sender
l_o_sender = cl_cam_address_bcs=>create_internet_address( 'emailaddressAsender.com' ).
l_o_send_request->set_sender( i_sender = l_o_sender ).
" recipient TO
l_o_recipient = cl_cam_address_bcs=>create_internet_address( 'emailtoArecipient.com' ).
l_o_send_request->add_recipient(
i_recipient = l_o_recipient
i_copy = '' " CC indicator).
" recipient CC
l_o_recipient = cl_cam_address_bcs=>create_internet_address( 'emailccArecipient.com' ).
l_o_send_request->add_recipient(
i_recipient = l_o_recipient
i_copy = 'X' " CC indicator).
" email contents
CLEAR l_wa_contents.
l_wa_contents-line = 'Dear Recipients,'.
APPEND l_wa_contents TO l_it_contents.
CLEAR l_wa_contents.
l_wa_contents-line = 'This in the contents attachments'.
APPEND l_wa_contents TO l_it_contents.
" create documents
l_o_document = cl_document_bcs=>create_document(
i_type = 'RAW' " RAW document format
i_text = l_it_contents
i_subject = 'This Is The Subject for Email With Attachment' ).
l_o_document->add_attachment(
i_attachment_type = 'PDF' " add PDF attachment
i_attachment_subject = 'PDF attachment'
i_att_content_hex = l_i_attachment ).
l_o_send_request->set_document( l_o_document ).
" send email
l_v_ret = l_o_send_request->send( ).
CATCH cx_bcs INTO bcs_exception. " exceptions, do something
ENDTRY.
COMMIT WORK. " never forget this one