on 05-20-2011 5:05 PM
Hi All.
I've a problem.
I use process chain EXPORT_TO_BADI and I'd like save data into BPC Server ( UJFS ).
Someone has any idea or simple code to save data?
I try to user some method in class CL_UJF_FILE_SERVICE_MGR especially method PUT_DOCUMENT_DATA_MGR
data : lo_save type ref to CL_UJF_FILE_SERVICE_MGR.
data : im_is_cd TYPE abap_bool.
im_is_cd = abap_true.
DATA: lt_content TYPE ujf_t_recline.
break-point.
i_doc_name = filename.
lo_save->put_document_data_mgr(
EXPORTING i_docname = i_doc_name
i_append = 'X'
i_doc_content = lt_content
i_content_delivery = im_is_cd ).
The fields i_doc_name must be : \ROOT\WEBFOLDER\<appl_set>\<appl>FILE_NAME.TXT ??
There are other way?
Thanks
Marco
Yes, that is the coding you want to use. But do not set the i_content_delivery paraemter to true. Doing so, will cause a problem. Pass ABAP_FALSE to it.
And yes, I_DOC_NAME requires you to pass the full path and file name just like you have mentioned.
Also, you need to create the instance of the file service manager into the lo_save reference variable. Use the FACTORY method of the CL_UJF_FILE_SERVICE_MGR class for this.
cl_ujf_file_service_mgr=>factory(
exporting
i_appset = p_appset
is_user = ls_user
receiving
r_manager = lo_save ).
The UJFS transaction(program UJF_FILE_SERVICE_UI ) was orginally created to simply test all file service APIs, so you can look at the code in this program, to see how to call the APIs.
Cheers,
Rich Heilman
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I know this is very old post but i got stuck at creating a file on the webserver...i am able to create the file but the file is blank even though i pass the data on the i_doc_content... the file is created with blank data...
below is the code
LV_DOCNAME = '\ROOT\WEBFOLDERS\ABC\ADMINAPP\11TEST.xml'.
<CONTENT> = ``. APPEND WA_CONTENT TO IT_CONTENT.
<CONTENT> = `UK, Amort, 1120, 1230,1220,470,1600,7900,1850,1900,1230,3200,3340,2560`.
APPEND WA_CONTENT TO IT_CONTENT.
CL_UJF_FILE_SERVICE_MGR=>FACTORY(
EXPORTING IS_USER = LS_USER
I_APPSET = P_APPSET
RECEIVING R_MANAGER = LO_FILE_SERVICE_MGR ).
CALL METHOD LO_FILE_SERVICE_MGR->PUT_DOCUMENT_DATA_MGR
EXPORTING
I_DOCNAME = LV_DOCNAME
I_APPEND = 'X'
I_DOC_CONTENT = IT_CONTENT
i_content_delivery = im_is_cd.
Please let me know if i am doing anything wrong.....
Thanks in adavance.
User | Count |
---|---|
13 | |
2 | |
2 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.