iLogic create fillet on drawing

iLogic create fillet on drawing

sbcJLYKK
Contributor Contributor
594 Views
4 Replies
Message 1 of 5

iLogic create fillet on drawing

sbcJLYKK
Contributor
Contributor

Hi

I hope I can get some help.

I'm very new to iLogic.

I have this foot plate, please see attached picture.

I need to get the roundings / fillets on the drawing.

I have surfed a lot on the web / youtube to find the iLogic code to be able to perform the function, but I can not find anything.


Now I am dyslexic and English is not my mother tongue so it could easily be that it has been missed for me.


I hope you can help me.

 

Regards

 

Steffen

0 Likes
Accepted solutions (1)
595 Views
4 Replies
Replies (4)
Message 2 of 5

Ralf_Krieg
Advisor
Advisor

Hello

 

Do you want to add the radius dimension by iLogic? Or do you want to  get the drawing curves which correspond to the fillet radius? Please explain a bit more in detail.


R. Krieg
RKW Solutions
www.rkw-solutions.com
0 Likes
Message 3 of 5

sbcJLYKK
Contributor
Contributor

Hi

R. Krieg.

Thank you so much for answering me.

That's really nice of you.


I am in the process of developing a template where the working drawing is generated automatically.

 

Where the relevant dimensions are automatically generated including the radius of the corners.

 

What I am asking for is how to add the radius dimension by iLogic 🙂

 

I have attached the ipt and dwg files which may be helpful with what I mean.

 

Thank you

 

Best regards Steffen.

0 Likes
Message 4 of 5

Ralf_Krieg
Advisor
Advisor
Accepted solution

Hello

 

This should add radius dimension to each radius created by a fillet feature on the active sheet in the first drawing view.

Dim oDrawDoc As DrawingDocument = ThisDoc.Document
Dim oSheet As Sheet = oDrawDoc.ActiveSheet
Dim oDrawView As DrawingView = oSheet.DrawingViews(1)

Dim oTrans As Transaction = ThisApplication.TransactionManager.StartTransaction(oDrawDoc, "AddRadiusDimension")
Try
	Dim oRefedDoc As PartDocument = oDrawView.ReferencedDocumentDescriptor.ReferencedDocument
	Dim oFilletFeature As Inventor.FilletFeature
	For Each oFilletFeature In oRefedDoc.ComponentDefinition.Features.FilletFeatures
		Dim oDrawCurves As Inventor.DrawingCurvesEnumerator = oDrawView.DrawingCurves(oFilletFeature)
		If oDrawCurves.Count>0 Then
			Dim oDrawCurve As DrawingCurve
			Dim oObjColl As ObjectCollection=ThisApplication.TransientObjects.CreateObjectCollection
			For Each oDrawCurve In oDrawCurves
				Dim oGeomIntent As GeometryIntent = oSheet.CreateGeometryIntent(oDrawCurve)
				Dim oCenterPoint As Point2d=oDrawCurve.CenterPoint
				Dim oMidPoint As Point2d = oDrawCurve.MidPoint 
				Dim oVector As Inventor.Vector2d = oCenterPoint.VectorTo(oMidPoint)
				oVector.ScaleBy(4)
				Dim oPoint As Point2d = oMidPoint
				oPoint.TranslateBy(oVector)
				
				Dim oGenDims As GeneralDimensions = oSheet.DrawingDimensions.GeneralDimensions
				oGenDims.AddRadius(oPoint, oGeomIntent )
			Next
		End If
	Next
oTrans.End

Catch ex As Exception
	MsgBox(ex.Message)
	oTrans.Abort
End Try

R. Krieg
RKW Solutions
www.rkw-solutions.com
0 Likes
Message 5 of 5

sbcJLYKK
Contributor
Contributor

Many thanks for your help. It worked.

It was really nice of you to help
0 Likes