Message 1 of 2

Not applicable
02-11-2015
12:14 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
I've been developing a rule that works very well except for one part. I dont know the proper syntax to measure an angle between selected faces using iLogic. The Measure.Angle command seems to be looking for string values (ex. a work plane's name). Does anyone know the proper syntax so I can have the rule check if the planes intersect?
I know using the measure tool is much simpler, but this is an example from a section of a more extensive rule i'm developing.
SyntaxEditor Code Snippet
Dim oAsmCompDef As AssemblyComponentDefinition oAsmCompDef = ThisApplication.ActiveDocument.ComponentDefinition Dim oPlane1 As Face oPlane1 = ThisApplication.CommandManager.Pick(SelectionFilterEnum.kAllPlanarEntities,"Select the face of the part") Dim oPlane2 As Face oPlane2 = ThisApplication.CommandManager.Pick(SelectionFilterEnum.kAllPlanarEntities,"Select an intersecting plane") oMeasure = Measure.Angle(oPlane1,oPlane2)
If oMeasure = 0 Or 180 Then
MessageBox.Show("Selected planes do not intersect. Please select intersecting planes.","iLogic")
Return
End If
Solved! Go to Solution.