Skip to Content
0
Jun 24, 2022 at 07:21 PM

Download of documents from archiv with document-type = 'FAX' not successful

106 Views

Hello together,


I am still struggling with my report for download of invoice-related documents from the archive.

For the downl,oad of PDF-attachments from invoices I was meanwhile successful.

Now there come a further requirements which is the download of consignment notes (CMR) from transports (business object VTTK).

I use the function module ALINK_DOCUMENTS_GET_CLIENT.

Therein I get a error-message from the function module SCMS_CLTFC_FILE_GET with the message "GetStream failed".

The difference to the invoice-attachments is that the consignment notes have document-type = 'FAX' (instead of 'PDF' with the invoice-attachments).


Does anybody of you have a hint for me?

The call of function modules ALINK_DOCUMENTS_GET_CLIENT is as following:

CALL FUNCTION 'ARCHIV_GET_CONNECTIONS'

EXPORTING
objecttype = 'VTTK'
object_id = l_object_id
TABLES
connections = lt_connections
EXCEPTIONS
nothing_found = 1
OTHERS = 2.

IF sy-subrc <> 0.

ELSE.

READ TABLE lt_connections INTO lw_connections INDEX 1.

* Download des Anhangs der Faktura nach generierter Datei

lv_document_class = lw_connections-reserve.

CALL FUNCTION 'ALINK_DOCUMENTS_GET_CLIENT'
EXPORTING
archiv_id = lw_connections-archiv_id
document_class = lv_document_class
archiv_doc_id = lw_connections-arc_doc_id
filename = '\\P1030.gruppe.local\_Austausch\Factoring_ungarn\Download_Frachtbrief.PDF'
IMPORTING
retfilename = fname_c
EXCEPTIONS
error_contentrepository = 1
OTHERS = 2.

Kind regards
Udo