Message 1 of 3
Inventor Vb.Net "Stand Alone" Verses "AddIn"
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Can anybody help?
I have the following Vb.Net code that works great with a "Stand Alone" appiclation.
Sub GetTubeDimensions(oDoc)
Dim oCompDef As PartComponentDefinition = oDoc.ComponentDefinition
Dim oSketch As PlanarSketch = Nothing
For Each oSketch In oCompDef.Sketches
Dim oSketchCircles As SketchCircles = oSketch.SketchCircles
Dim oSketchCircle As SketchCircle
If oSketchCircles.Count = 2 Then
For Each oSketchCircle In oSketchCircles
Counter += 1
Dim oDia As Double = (oSketchCircle.Radius * 2) * 10
IMsgbox(oDia)
Next
End If
Next
End Sub
However, when I use the above code in a Inventor Vb.Net "AddIn" the code does not work.
Does anybody know how the code needs modifying to make it work in an "AddIn"?
Many thanks in advance!
Darren

