Message 1 of 3

Not applicable
08-02-2018
03:19 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hi Guys,
I'm looking for the solution of following problem:
I'd like to use iLogic rule to check if a sketch (There will be only one used for part creation) was definied on XY plane or not.
I need this information for further part area calculation (with Measure.ExtentsWidth and Measure.ExtentsLength
function).
Right now I have a piece of code which dosen't work:
SyntaxEditor Code Snippet
On Error Resume Next Dim oDoc As PartDocument oDoc = ThisDoc.Document Dim oDef As PartComponentDefinition oDef = oDoc.ComponentDefinition Dim oSketch As PlanarSketch oSketch = oDef.Sketches.Item(1) Dim xyPlane As Inventor.WorkPlane xyPlane = oDef.WorkPlanes.Item(3) If oSketch.WorkPlanes <> xyPlane Then MessageBox.Show("Sketch needs to be definied on XY plane!", "iLogic") Exit Sub End If
Thanks in advance for any help.
Best Regards
Tomek
Solved! Go to Solution.