NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

TS Session Manager doesnt return Names of CUSTOM Categroy

Using Session Manager API one can retreive Session Categories and (declared) Names in Categories.
When i open a *CUSTOM::XXX Session an place String or numeric Values to this Session i expect,
when performing Method [Get Names] on *CUSTOM::XXX that Session Manager returns the name or
all my Custom entries.
Why does SM not return those names.
0 Kudos
Message 1 of 3
(2,731 Views)

GetNames returns the names of all the sessions the session manager knows how to create (whether or not they are already created in memory).  Since the session manager doesn't know the names of custom sessions you might potentially want to create, GetNames never returns custom session names.

To get the names of custom sessions you have already created, you can call GetSessions and access the name property of each session.

Note that you should probably be passing false to newSession parameter of GetInstrSession. Otherwise, if you pass true, you get a new distinct session object whether or not a session object already exists with the name you specify. In addition, the new session object will have its name altered to reflect it's uniqueness, even if a session with the specified name did not previously exist.

 

 

0 Kudos
Message 2 of 3
(2,719 Views)
Hello James,
 
thank you for your reply. It wasn´t really the answer i had expected but it
gave me an idea to look further.
To close my request i´ve enclosed my solution i found.
The problem was, to get the information which Data Items !!! were declared.
There is no specific method to retreive this names but
the state description gives me those information also so the problem is solved.
 
Please find enclosed a sample for clarifying this.
 
Many thanks and
best regards
 
Hacky 
0 Kudos
Message 3 of 3
(2,706 Views)