Announcements
Attention for Customers without Multi-Factor Authentication or Single Sign-On - OTP Verification rolls out April 2025. Read all about it here.
neodd70
in reply to: Anonymous

@Anonymous When running a rule from the iLogic IDE you need to have a Main Sub and then call your other Sub from within the Main or just put your code in the Main Sub. Also the "Set" command is an invalid command in the iLogic IDE so those just need to be removed. Try this

Sub Main()
	Door_Corners()
End Sub

Sub Door_Corners()

Dim oDoc As PartDocument
oDoc = ThisApplication.ActiveDocument

Dim oDef As PartComponentDefinition
oDef = oDoc.ComponentDefinition

Dim oPoint As Vertex
oPoint = ThisApplication.CommandManager.Pick(kPartVertexFilter, "Right Side")

Dim wp1 As WorkPoint
wp1 = oDef.WorkPoints.AddByPoint(oPoint)

End Sub