07-22-2016 01:14 PM
Is there a way to create a multi-channel DaqMX task programatically, without having a task to copy?
Solved! Go to Solution.
07-22-2016 01:19 PM
Yes and there is an easy way to figure out how to do it.
Start by creating a task in MAX (But Ben I want to avod MAX! Have no fear this is just a one time event that will let us learn what is involved)
Go to a block diagram and drop a DAQmx task constant on the diagram and choose the task you created in MAX.
Right-click it and select "create configuration and example". LV will create the code that goes with the taks.
Study the config VI that was created. It will show what needs to be done to create a task without MAX.
I hope that helps!
Ben
07-22-2016 01:27 PM
It is a thing of beauty. You are truly a gentleman and a scholar Sir Ben!
07-22-2016 01:27 PM
@JaNeily wrote:Is there a way to create a multi-channel DaqMX task programatically, without having a task to copy?
The DAQmx Create Virtual Channel is what is used to add channels to a task. There is also a DAQmx Create Task which creates and empty task that you can add the channels to.