DIAdem

cancel
Showing results for 
Search instead for 
Did you mean: 

Using DataFileLoadSel with Multiple Channel Names

Hi,
 
Is it possible to selectively load many channels with one DataFileLoadSel, asking for channel names, rather than numbers?  The help appears to be somewhat misleading, as it says you can only use the [Group index]/[Channel index] format, rather than channel name.  However, I was able to selectively load one channel by using:
 
Call DataFileLoadSel(DataFilename, "TDM", "*/EngineSpeed")
 
But I have not been able to ask for multiple channel-names in one command successfully.  Is this possible?  If not, I can just do multiple commands, but this is less preferable. 
 
Thank you!
Julia
0 Kudos
Message 1 of 3
(3,213 Views)

Hi Julia,

I have noticed this in the past also and been puzzled by it.  I tried out a bunch of things and then emailed R&D on the topic.  The answer from R&D is that for DataFileLoadSel(), selected channel referencing is officially only supported when the group and channel are provided with indices, as shown in the Online Help.  It turns out that more works than that in DIAdem 10.2, but the response from R&D is that anything else is not an official feature and you're on your own with DIAdem 10.2 if you try syntax options with group or channel names and don't like the way DIAdem behaves.

That said, I noticed that the following attempts succeeded:

FilePath = "C:\Documents and Settings\All Users\Documents\National Instruments\DIAdem 10.2\Data\Example.TDM"
Call DataDelAll
Call DataFileLoadSel(FilePath, "TDM", "[1]/*")
Call DataFileLoadSel(FilePath, "TDM", "[1]/T*")
Call DataFileLoadSel(FilePath, "TDM", "*/[1]")
Call DataFileLoadSel(FilePath, "TDM", "*/T*")
Call DataFileLoadSel(FilePath, "TDM", "[1]/Time")
Call DataFileLoadSel(FilePath, "TDM", "Example/Time")
Call DataFileLoadSel(FilePath, "TDM", "Example/[1,2,4]")
Call DataFileLoadSel(FilePath, "TDM", "[1,2,3]/T*")
Call DataFileLoadSel(FilePath, "TDM", "[1]/[1-4]")
Call DataFileLoadSel(FilePath, "TDM", "[1]/[1,2,4]")

The common theme seems to be that if you use anything other than indices for group or channel referencing, then you can only reference one of them-- there seems to be no way to reference a list or a range of group or channel names.  Both a referenced list and a referenced range do work with group or channel indices, and a mixture of name and index referencing seems to always work as long as the name part does not attempt a list or range.

Hope that helps,
Brad Turpin
DIAdem Product Support Engineer
National Instruments

Message 2 of 3
(3,196 Views)
Thank you Brad!  Though not the answer I was hoping for, it is good to have a list of known ways that do work.
0 Kudos
Message 3 of 3
(3,192 Views)