I have created some Associative points and renamed like point1, point2 etc, and added in layer 10, below is my code
Option Strict Off
Imports System
Imports NXOpen
Imports NXOpenUI
Imports NXOpen.UF
Imports NXOpen.Utilities
Module Module1
Dim theSession As Session = Session.GetSession()
Dim theUFSession As UFSession = UFSession.GetUFSession()
Dim workPart As Part = theSession.Parts.Work
Dim lw As ListingWindow = theSession.ListingWindow
Sub Main()
lw.Open()
For Each myPoint As Point In workPart.Points
If myPoint.Layer = 10 Then
lw.WriteLine(myPoint.Name)
lw.WriteLine(myPoint.Coordinates.ToString)
End If
Next
End Sub
End Module
When I execute above code I am getting coordinates but not names of points
can you please let me know where is problem in my code and I need names of these points please help me
Thanks