on 02-12-2009 7:39 AM
Hello,
I want open a document stored in DMS through RFC BAPI, from an external application (for example .NET)
EasyDNS run OK: I have included the bapi Z_EASYDMS_ECL_OPEN_DOCUMENT (code from a SAP note) in the system and I can open ECL/EAI & local documents (pdf, word, ...)
If I run Z_EASYDMS_ECL_OPEN_DOCUMENT from SE37 run OK: I can see every document, document is downloaded to local system and then open.
But when I call bapi Z_EASYDMS_ECL_OPEN_DOCUMENT from my external application through RFC I don't receive any result: document is not download to local system.
I have debugged the bapi (with SM50) and I have see that the calling entry in bapi, run and then ... crash.
I have detected the fail in OLE_FLUSH_CALL: system has a dump.
Summary:
- EasyDMS run Ok
- SE37 Z_EASYDMS_ECL_OPEN_DOCUMENT run ok
- Z_EASYDMS_ECL_OPEN_DOCUMENT dump at OLE_FLUSH_CALL
Any idea?
thanks in advance,
Hello,
it is possible to extract DMS's file to application server directory:
FUNCTION Z_DMS_VIEW.
*"----
""Interfase local
*" IMPORTING
*" VALUE(DOC_NUMBER) LIKE BAPI_DOC_DRAW2-DOCUMENTNUMBER OPTIONAL
*" VALUE(DOC_PART) LIKE BAPI_DOC_DRAW2-DOCUMENTPART OPTIONAL
*" VALUE(DOC_TYPE) LIKE BAPI_DOC_DRAW2-DOCUMENTTYPE OPTIONAL
*" VALUE(DOC_VERS) LIKE BAPI_DOC_DRAW2-DOCUMENTVERSION OPTIONAL
*" VALUE(ORIGINAL_PATH) LIKE BAPI_DOC_AUX-FILENAME OPTIONAL
*" EXPORTING
*" VALUE(P_RETURN) LIKE BAPIRET2 STRUCTURE BAPIRET2
*" TABLES
*" DOC_FILES STRUCTURE BAPI_DOC_FILES2 OPTIONAL
*"----
CLEAR: doc_files.
REFRESH: doc_files.
DATA: i_doc_files like bapi_doc_files2.
DATA: i type i.
*
i = 2.
while i = 2.
i = 2.
endwhile.
CALL FUNCTION 'BAPI_DOCUMENT_CHECKOUTVIEW2'
EXPORTING
DOCUMENTTYPE = DOC_TYPE
DOCUMENTNUMBER = DOC_NUMBER
DOCUMENTPART = DOC_PART
DOCUMENTVERSION = DOC_VERS
DOCUMENTFILE = i_doc_files
GETSTRUCTURE = '0'
GETCOMPONENTS = 'X'
ORIGINALPATH = ORIGINAL_PATH
HOSTNAME = ' '
GETHEADER = 'X'
PF_HTTP_DEST = 'SAPHTTPA'
PF_FTP_DEST = 'SAPFTPA'
IMPORTING
RETURN = P_RETURN
TABLES
DOCUMENTFILES = DOC_FILES.
ENDFUNCTION.
ORIGINAL_PATH must be a directory of application server.
By background is not possible (I don't know how can we do that) download thsi file to PC.
Then with the file in application server we can :
- to map application server directory in a drive unit of Pc
- to transfer with a ftp client from Pc
- rfcexec
But always the bapi can not download the file: it must be a process in Pc who transfer the file.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
No Thierry, I have not found any solution, yet.
I suspect that EasyDMS work with some component of SAPGUI, but I have not found any information about this.
greetings,
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I have the same problem. Do you have find a solution ?
Thierry
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
99 | |
11 | |
11 | |
6 | |
6 | |
4 | |
4 | |
3 | |
3 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.