DIAdem

cancel
Showing results for 
Search instead for 
Did you mean: 

Problem: Navigator.Events.OnLoaded for channel group processing

I'm trying to call a function everytime the user imports a channel group into the data portal. Assigning a function to Navigator.Events.OnLoaded works great if the user selects some channelgroups in the datafinder.  But when importing all channel groups as one by selecting the containing *.tdm file, the function doesn't get called for every channel group! Is there a workaround for this problem?
 
Thank you!
0 Kudos
Message 1 of 2
(3,411 Views)

Hi Stjag,

The Navigator.Events.OnLoaded() event is called once after a load event is finished.  There is also a Navigator.Events.OnFileLoading() event and a Navigator.Events.OnDataStoreLoading() event which are called once before a load event starts (for file/sever loading respectively).  You could use the pre-loading event to store the last group index before loading, then use the post-loading event to manually loop over all the new groups and call your own function once for each new group.

Bear in mind, however, that a loading event can also be a collection of channels from a variety of files or server locations, which would then be placed in a new group with an auto-generated name.  Loading in DIAdem is not specific to groups-- file loading and channel loading are also valid, and regardless of type there is only one Navigator event call per loading event.

Brad Turpin
DIAdem Product Support Engineer
National Instruments

0 Kudos
Message 2 of 2
(3,404 Views)