on 01-08-2007 10:35 AM
Hi
I'm do'g an offline interactive pdf form in which i'm using the func.SCMS_XSTRING_TO_BINARY to get the generated pdf and convert into binary format.This func.mod has got a tables para 'binary_tab'.What should be the table of the parameter to be passed to this...becoz in the later stage of prog. its raising an error <b>"LT_ATT_CONTENT_HEX" is not type-compatible with formal parameter "I_ATT_CONTENT_HEX".</b> when i passed a char field table type to it.
If i couldn't make it clear to you....Please go through the code snippet below...
And reply me soon...
begin of lt_att_content_hex occurs 0,
binary(200),
end of lt_att_content_hex.
CALL FUNCTION 'SCMS_XSTRING_TO_BINARY'
EXPORTING
BUFFER = formoutput-pdf "PDF file from function
"module
* APPEND_TO_TABLE = ' '
* IMPORTING
* OUTPUT_LENGTH =
TABLES
BINARY_TAB = lt_att_content_hex
.
CLASS cl_bcs DEFINITION LOAD.
DATA:
lo_send_request TYPE REF TO cl_bcs VALUE IS INITIAL.
lo_send_request = cl_bcs=>create_persistent( ).
* Message body and subject
DATA:
lt_message_body TYPE bcsy_text VALUE IS INITIAL,
lo_document TYPE REF TO cl_document_bcs VALUE IS INITIAL.
APPEND 'Dear Vendor,' TO lt_message_body.
append ' ' to lt_message_body.
APPEND 'Please fill the attached form and send it back to us.'
TO lt_message_body.
append ' ' to lt_message_body.
APPEND 'Thank You,' TO lt_message_body.
lo_document = cl_document_bcs=>create_document(
i_type = 'RAW'
i_text = lt_message_body
i_subject = 'Vendor Payment Form' ).
DATA: lx_document_bcs TYPE REF TO cx_document_bcs VALUE IS INITIAL.
TRY.
lo_document->add_attachment(
EXPORTING
i_attachment_type = 'PDF'
i_attachment_subject = 'Vendor Payment Form'
* I_ATTACHMENT_SIZE =
* I_ATTACHMENT_LANGUAGE = SPACE
* I_ATT_CONTENT_TEXT =
* I_ATTACHMENT_HEADER =
i_att_content_hex = lt_att_content_hex ).
Hi,
use
data: lt_hex_tab TYPE solix_tab.
for your binary table
regards
Maik
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
85 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.