i have a new requirement in customer account statement. for example i have 100 customers. the account statement about 30 customers want to receive by email and 35 customers want to receive by fax and the remaining 35 want to receive by printout via post.
pls guide me. very urgent.
I am poviding you the programs to send SF via Mail (in the first one) and via Fax(in the second one). You merge these two programs or declare the inputs specifically for the customers as per your requirement, to mail or fax and give them (customer no.s) as input to these programs in two diferent programs.
1 . When you call the smart form FM, you can get the OTF data in a tables parameter.
You can convert the OTF data into PDF data using the function module.
All activities done via facade CL_BCS!
DATA: send_request TYPE REF TO cl_bcs.
DATA: document TYPE REF TO cl_document_bcs.
DATA: sender TYPE REF TO cl_sapuser_bcs.
DATA: bcs_exception type ref to cx_bcs.
APPEND 'Hello world!' TO text.
i_subject = 'test created by BCS_EXAMPLE_2' ).
APPEND 'This is an attachment' TO text.
CALL METHOD send_request->set_document( document ).
set automatically with actual user.
sender = cl_sapuser_bcs=>create( sy-uname ).
create recipient - please replace fax number !!!
* with your own one !!!
For the settings, check with your bais admin.
Your problem will be rectified.
This requirement should be get by configuring different output types for different outputs.
And for each output type we configure the output accordingly.