Altojoe
New member
- Mar 16, 2013
- 23
How to ref the symbols in journal
i created one journal to move all the symbols to layer 254 as following. but it is showing an error symbol is not a part of NXOPEN.Annotations.AnnotationManager
I dont know how it will read in jornal for symbols i want all the subtypes needs to be selected in this method. like crosshatch, id symbols, centerlines etc.
When i do only for centerlines or id symbols i am getting the action. But not for all.....
Option Strict Off
Imports System
Imports NXOpen
Imports System.Collections.Generic
Module NXJournal
Sub Main
Dim theSession As Session = Session.GetSession()
Dim workpart As Part = theSession.Parts.Display
Dim hatch1 As Annotations.Hatch
Const SymLayer as Integer = 254
[highlight #FCE94F]For each CrosshatchObj as DisplayableObject In workpart.Annotations.symbols[/highlight]
'if typeof(CrosshatchObj) is Crosshatch then
CrosshatchObj.Layer = CrosshatchLayer
CrosshatchObj.RedisplayObject
'end if
next
End Sub
End Module
i created one journal to move all the symbols to layer 254 as following. but it is showing an error symbol is not a part of NXOPEN.Annotations.AnnotationManager
I dont know how it will read in jornal for symbols i want all the subtypes needs to be selected in this method. like crosshatch, id symbols, centerlines etc.
When i do only for centerlines or id symbols i am getting the action. But not for all.....
Option Strict Off
Imports System
Imports NXOpen
Imports System.Collections.Generic
Module NXJournal
Sub Main
Dim theSession As Session = Session.GetSession()
Dim workpart As Part = theSession.Parts.Display
Dim hatch1 As Annotations.Hatch
Const SymLayer as Integer = 254
[highlight #FCE94F]For each CrosshatchObj as DisplayableObject In workpart.Annotations.symbols[/highlight]
'if typeof(CrosshatchObj) is Crosshatch then
CrosshatchObj.Layer = CrosshatchLayer
CrosshatchObj.RedisplayObject
'end if
next
End Sub
End Module