cancel
Showing results for 
Search instead for 
Did you mean: 

How is it posibile to delete an entry of an original file from a DIR

Former Member
0 Kudos

hello,

i have the following problem: i use the bapi bapi_document_change2 form vb to change

a document (DIR:Document Info record). I can also add a new original file like XXXXX.TIF to the DIR .

With every run of bapi_coument_change2 i get new entries in the list of the original files.

So at the end i have more and more originale file linked to the DIR.

The aim is that i have only the newest file linked with the DIR and the older entries

are deleted ( the problem is not to delete the original file in the file system , the problem is how

to delete the entry in the sap database. So my hope is that it should be possible to delete this

enttries by bapi_document_change2.

By hand it is posible to change the despription of the originale file.

It is also posible to delete the entry.

I tried to create a batchinput but the recorder does not record at this specioal point something

to delete the entry.

Has anybody perhaps some expirience with this problem (delete the entry of an original file in a DIR)?

Perhaps a little abap example ?

Would be very nice to get an answer.

with regards

Guenter

Edited by: Hans Günter Weishaupt on Feb 12, 2009 3:05 PM

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi Günter,

I have an issue to delete the Review Comments/Notes and Interim Versions of a DIR in CV02N in the Originals tab in a Z-program. Here if you double click on the document created(PDF or Word doc.) and go inside it, you can find a LAYER pushbutton having a drill down which has Original, Layer, Layer1 etc... Upon its selection, we can see cross lines, eclipses that are marked by the User(These are called Redlines).

Now if the User releases a DIR, the Review Comments/Notes, Interim Versions and Redlines should be deleted.

Since you have worked on a similar issue, can you provide info as to how can we complete this requirement? In the meanwhile I will go through the FMs below as you have mentioned in one of your postings earlier.

Bapi_Document_Create2

Bapi_Document_Change2

Bapi_Document_Getdetail2

If you are using KPRO you need to use

CVAP_Doc_Getdetail

CVAP_Doc_Change

(that was my problem)

Also can you elaborate what is this KPRO??

Thanks in advance,

Susanth

Former Member
0 Kudos

hi

You can ask your basis person to delete the files from the physical directory.

Former Member
0 Kudos

Hello AP,

thank you for your answer BUT that is not the problem !

The problem is not to delete it from a physical directory.

With DIR i mean :Document Info record and NOT Directory.

If you use CV02N for changing an document you get the view of the document.

In the area of originals you get a list of files that are connect with the DIR.

I my case normaly one document (a tif file) is connect to the DIR.

Now i want to delete an entry in this list (not the file) !

In SAP I click to this entry and can use: the wastebasket or with the

mouse: right button and use delete !

I want to delete this entry with a bapi or an rfc or an batchinput . That is what i am looking for .

With batchinput i have the problem that i can not select the entry (it is not recorded).

with bapi_document_change2 i wasn't successfull . There is a Delete parameter by it does'nt work

so far .

thanks Günter

Former Member
0 Kudos

Hi,

i found the solution . See under "Use of DELETEVALUE with bapi_document_change2".

Because of the KPRO switch you have to use CVAPI_DOC_CHANGE .

regards

Former Member
0 Kudos

hi

i am nerw to DMS. i have to change the file path for a group of DIR's. can you give me details how i can do this.

Thanks in advance. Sri

Former Member
0 Kudos

Hi Sri,

please have a look to the following Bapis:

Bapi_Document_Create2

Bapi_Document_Change2

Bapi_Document_Getdetail2

If you are using KPRO you need to use

CVAP_Doc_Getdetail

CVAP_Doc_Change

(that was my problem)

Normaly you need Documentnumber,Documenttype,Documentversion to find the

Documentinforecord.

In CVAPI_Doc_Change there is the table: CVAPI_DOC_FileTable.

There your can save the description, filename and the sourcedatacarrier (means the

name of the physical directory).

regards

Günter

Former Member
0 Kudos

Hi Sri,

i have a second info:

You start SPRO to get into the customizing . Then you have the 4. entry:

Anwendungsübergreifende Komponenten (in englisch ? ....components ?) .

The second entry is: global data (that's my translation of course)

Then the second: define sourcedatacarrier (in english?)

I hope you will find it.

Here you can define the directories for DMS.

The last point are the mountpoints.

The mountpoints are like a shortname for a long physical directory name.

This is the same what i mean with sourcedatacarrier in the bapi cvapi_doc_change.

If you change here in the customizing the entry of the physical name all files will be searched in this new

directory. Then you have only to copy the physical files to this new directory and the work is done.

But this is a global change of all files !

I think this only works if you are not using a safe (that is the way i am working).

regards

günter

with regards

Günter