Correct iLogic syntax

Correct iLogic syntax

arron.craig
Collaborator Collaborator
536 Views
2 Replies
Message 1 of 3

Correct iLogic syntax

arron.craig
Collaborator
Collaborator

I have the following in an iLogic script which sets the body type of the derived part and I would like to also remove objects by visibility and patch some holes. 

 

'create the derived assembly deffinition
Dim oDerivedAssemblyDef As DerivedAssemblyDefinition 
oDerivedAssemblyDef = oPartDoc.ComponentDefinition.ReferenceComponents.DerivedAssemblyComponents.CreateDefinition(sPathandName & ".iam")

 

I believe I need 

 

DerivedAssemblyDefinition.GetRemoveByVisibilityOptions(DerivedGeometryRemovalEnum.kDerivedRemovePartsAndFaces, VisibilityPercentage = 50, IgnoreSurfaceFeatures = True) 

 

and 

 

DerivedAssemblyDefinition.SetHolePatchingOptions(DerivedHolePatchEnum.kDerivedPatchAll)

 

But I don't know how to combine these arguments, any help would be great

0 Likes
Accepted solutions (1)
537 Views
2 Replies
Replies (2)
Message 2 of 3

Anonymous
Not applicable
Accepted solution

Try the following:

 

Call oDerivedAssemblyDef.SetHolePatchingOptions(DerivedHolePatchEnum.kDerivedPatchAll)
Call oDerivedAssemblyDef.SetRemoveByVisibilityOptions(DerivedGeometryRemovalEnum.kDerivedRemovePartsAndFaces, 50, True)

Regards,

 

Maarten

Message 3 of 3

arron.craig
Collaborator
Collaborator

Thanks Marten, Works perfectly. 

0 Likes