Greetings Naughty Bunny,
Your identical post is being answered
here. As Filippo mentioned, you must use a comma to delimit channels and another helpful tool is the DAQmx error checking. This helps provide useful descriptions of errors that may occur in your code, as well as give suggestions for fixes when trying to acquire from multiple channels.
EXAMPLE:
DAQmxErrChk (DAQmxCreateTask("",&gTaskHandle));
DAQmxErrChk (DAQmxCreateAIVoltageChan(gTaskHandle,chan,"",DAQmx_Val_Cfg_Default,min,max,DAQmx_Val_Volts,NULL));
DAQmxErrChk (DAQmxCfgSampClkTiming(gTaskHandle,"",rate,DAQmx_Val_Rising,DAQmx_Val_ContSamps,sampsPerChan));
DAQmxErrChk (DAQmxGetTaskAttribute(gTaskHandle,DAQmx_Task_NumChans,&gNumChannels));
Thanks and good luck!
Jordan Randall
National Instruments Italy