Hi @gma
If you need to run this over all views in the sheet, note that projected views with hidden lines might result in the top edge of the hole being picked up and a center mark applied, which would typically not be what we want. Something like this example will allow those linear thread curves to be skipped.
I hope this helps.
Best of luck to you in all of your Inventor pursuits,
Curtis
http://inventortrenches.blogspot.com
Dim oDrawingDoc As DrawingDocument = ThisApplication.ActiveDocument
Dim oSheet As Sheet = oDrawingDoc.ActiveSheet
Dim oView As DrawingView
For Each oView In oSheet.DrawingViews
Dim oCurve As DrawingCurve
For Each oCurve In oView.DrawingCurves
If Not oCurve.EdgeType = DrawingEdgeTypeEnum.kThreadEdge Then Continue For
If oCurve.ProjectedCurveType = Curve2dTypeEnum.kCircleCurve2d Or _
oCurve.ProjectedCurveType = Curve2dTypeEnum.kCircularArcCurve2d Then
Dim intent1 As GeometryIntent
intent1 = oSheet.CreateGeometryIntent(oCurve)
oSheet.Centermarks.Add(intent1)
End If
Next
Next