DIAdem

cancel
Showing results for 
Search instead for 
Did you mean: 

I would like to get only specific channels from several .csv files and concatenate into one group.

Hi Maria,

 

In DIAdem 2011 we updated the DataFileLoadSel() command to accept a full "Group/Channel" string just like you would use in DIAdem.

 

Does that help?

Brad Turpin

DIAdem Product Support Engineer

National Instruments

0 Kudos
Message 11 of 13
(639 Views)

Hi Brad!

 

Thank you for your help.

I try in the way you recommend me, but it only let me load one specific channels. I have a list of the channels names which I want to load, but this way I dont know how to write several names to be loaded.

 

When is with indexes is easier because you write like [1]/[1,3,5,6] and it loads the selected channels, but when I try this way with the names [1]/Torque,Speed, DIAdem gives me an error.

 

Is there other way of doing this?

 

Thank again

0 Kudos
Message 12 of 13
(629 Views)

Hi marispaulies,

 

As far as I know if you reference the channel to load with a GroupName/ChannelName string or a [GroupIndex]/ChannelName string, you can only load one channel at a time.  I also find this frustratingly restrictive.  One workaround is to just call DataFileLoadSel() for each channel you want to load this way.  That works fine for a binary file that reads quickly but results in slow loading for complicated ASCII or Excel or XML data files.  Another option is to load all the channels with DataFileLoad() and delete the channels you don't want, but that can also be very slow if you just want to load a small portion of the file.

 

One final option would be to register-load the data file, figure out the channel indexes you want from the register-loaded channels, then delete them and make one call to DataFileLoadSel() with all the channel indexes you want packed together.  This still parses the data file twice, but if you want to load 10 out of 200 channels, it's better than 10 calls to DataFileLoadSel().  If you just want to load 2 or 3 channels per file it's not really any better than individual DataFileLoadSel() calls for each channel and therefore not worth the extra complexity.

 

Brad Turpin

DIAdem 

Message 13 of 13
(617 Views)