Continue to Site

Welcome to MCAD Central

Join our MCAD Central community forums, the largest resource for MCAD (Mechanical Computer-Aided Design) professionals, including files, forums, jobs, articles, calendar, and more.

How to delete a external class in j/link

ajoy

New member
I want to delete a external class which is stored in a model using jlink.


showing excception like this :
<BLOCKQUOTE dir=ltr style="MARGIN-RIGHT: 0px">


com.ptc.pfc.Implementation.pfcExceptions$XBadExternalData
at com.ptc.pfc.Implementation.pfcExternal$ExternalDataClass.Del ete(Native Method)</BLOCKQUOTE>


Thisis the code....


ExternaldataAccess =model.AccessExternalData();
ExternaldataAccess.LoadAll();


ExternalDataClasses ExternaldataClasses =ExternaldataAccess.ListClasses();
for ( int i = 0; i < ExternaldataClasses.getarraysize();i++)


{
ExternalDataClass ExternaldataClass =ExternaldataClasses.get(i);

if((ExternaldataClass.GetName().equalsIgnoreCase(selected_se t))) {
if(ExternaldataClass.IsValid(){
ExternaldataClass.Delete();
}
}
}


can anybody help me to solve this ?
 
I got no responses from this forum,but i put a log in PTC . they issued a SPR for Delete function in ExternalDataClass
 
I noticed the same behavior with Pro/WebLink. An exception was thrown on deletion, but the class was in fact deleted. Did you see the same?
 

Sponsor

Back
Top