How to perform SaveAs on WTPart using API in Windchill PDMLink 10.0 |
How to perform SaveAs on WTPart using API |
Windchill PDMLink 10.0 |
wt.enterprise.EnterpriseService.
newMultiObjectCopy(RevisionControlled[] originalObjects)
wt.enterprise.EnterpriseService. saveMultiObjectCopy(CopyObjectInfo[] copyInformation)
RevisionControlled [] originals = new RevisionControlled [1];
CopyObjectInfo [] copyInfoArray = null; originals[0] = part; copyInfoArray = EnterpriseHelper.service.newMultiObjectCopy(originals); WTPart copy = (WTPart) copyInfoArray [0].getCopy(); copy.setName(part.getName() + "_copy"); copy.setNumber(part.getNumber() + "_copy"); copy.setContainer(part.getContainer()); try { copyInfoArray = EnterpriseHelper.service.saveMultiObjectCopy(copyInfoArray); } catch (Exception e) { } |