Quantcast
Channel: SCN : Discussion List - SAP Sourcing
Viewing all articles
Browse latest Browse all 1416

How to delete document links via script?

$
0
0

Hi,

 

I am trying to write an import lifecycle script to delete all document links for a document say: project. 

I've tried the following code, but it keeps throwing me Indexoutofbound exception, can some one help on why this error happens?

 

docLinks = doc.getDocumentLinkList();

docLinksSize = docLinks.size();

if(docLinksSize > 0){
for (int i=docLinksSize; i>0; i--){

 

docLinks.delete(docLinks.get(i-1));

 

 

}

}

 

Thanks.


Viewing all articles
Browse latest Browse all 1416


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>