cancel
Showing results for 
Search instead for 
Did you mean: 

Not able to upload Documents using BAPI_DOCUMENT_CREATE2 (From SE37)

Former Member
0 Kudos

Hi

Not able to upload and created Document in SAP DMS Repository using Function BAPI_DOCUMENT_CREATE2.

I'm using this BAPI directly from SE37.

Alwasy it is giving Error - E26 253 Error while checking in and storing:c:\ZANALYSIS_PATTERN.XLS

Inputs I have given -

In Document Data -

Document Type - SDC

Document Version- 00

Document Part - 000

Description - TEST

In Document Files -

Document Type - SDC

Document Version- 00

Document Part - 000

Storage Category - ZHCL_CS

WS Application - XLS

DocPath - C:\

DocFile - C:\ZANALYSIS_PATTERN.XLS

Language - EN

CheckedIn - X

PF_FTP_DEST - SAPFTPA

PF_HTTP_DEST - SAPHTTPA

DEFAULTCLASS - X

Please advice if I had skipped something and mentioned anything wrong.

Thanks

Prashant

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi,

I know this is a very late response, but using a Bapi_Document_create2 or any other for that matter from Se37 will run successfull as you describe giving the internal document number. But it won't create as you need a commit work and wait function afterwards.

Therefore in Cv02n or cv03n it will say document does not exist.

Phillip

Former Member
0 Kudos

Hi Prashant,

Are you able to upload the same document via CV01N using the same storage category - ZHCL_CS ?

Regards,

Vivek

Former Member
0 Kudos

Hi Vivek

Thanks for the reply.

Yes I'm able to upload the Documents using standard Transaction Code - CV01N.

Please advice further.

Regards

Former Member
0 Kudos

Hi,

In that case, try specifying the entire file path in DOCPATH instead of DOCFILE. Keep DOCFILE blank.

We are using the same approach and it works for us.

Also try keeping PF_FTP_DEST and PF_HTTP_DEST blank.

Let me know if that helps.

Regards,

Vivek

Former Member
0 Kudos

Hi Vivek

Thanks, I have tried this earlier, it doesn't give error it provides me with an Internal Document No. but when I use CV02N to access the same, it displays message "Document Does not exists"

Am I missing someting...

Please advice.

Regards

Former Member
0 Kudos

Hi

Further to my earlier Mail, If I create on Dcument Manually in CV01N, i am able to attach Document to that using CVAPI_DOC_CHECKIN.

But not able to crate a docuement using BAPI_DOCUMENT_CREATE2 or BAPI_DOCUMENT_CREATE

Please advise.

Thanks

Former Member
0 Kudos

HI,

I am also uploading a pdf file to dms through bapi_document_checkin.

I am getting error E26 253 Error while checking in and storing:C:\DOCUMENTS AND SETTINGS\AGARW01S\DESKTOP\10 2_VIEW 1.PDF

Inputs I have given -

In Document Data -

Document Type - SPE

Document Version- A

Document Part - 000

Description - UPLOAD

In Document Files -

Document Type - SPE

Document Version- A

Document Part - 000

Storage Category - DMS_C1_ST

WS Application - PDF

DocPath - C:\DOCUMENTS AND SETTINGS\AGARW01S\DESKTOP\10 2_VIEW 1.PDF

DocFile - 10 2_VIEW 1.PDF

Language - EN

CheckedIn - X

PF_FTP_DEST - SAPFTPA

PF_HTTP_DEST - SAPHTTPA

can u please help me as it is urgent.

Shilpa

Former Member
0 Kudos

Use FM -    BAPI_DOCUMENT_CREATE2

Regards

christoph_hopf
Advisor
Advisor
0 Kudos

Hi Shilpa,

I think that maybe the data in

DocPath - C:\DOCUMENTS AND SETTINGS\AGARW01S\DESKTOP\10 2_VIEW 1.PDF

DocFile - 10 2_VIEW 1.PDF

could cause this issue. Because here you enter the filename '10 2_VIEW 1.PDF' in both fields. I would recommend you to fill the filename only in field DocFile and so the data should look like:

DocPath - C:\DOCUMENTS AND SETTINGS\AGARW01S\DESKTOP\

DocFile - 10 2_VIEW 1.PDF

For further information please see the SAP note 766277 where you will find a detailed documentation on all DMS BAPIs in the attachment area of the note.

Best regards,

Christoph