Thanks Bilal,
As I'm only using 8 bits anyway, that won't be a problem for me!
I've added the digital read and write code to my ActiveX control, emulating the traditional API's functions to set the data direction register by setting the appropriate line specifications in the "tasks", which means applications which my OCX will be able to use the new system unchanged.
I had to add another declaration for writing:
Declare Function DAQmxWriteDigitalScalarU32 Lib "nicaiu.dll" (ByVal taskHandle As Long, ByVal AutoStart As Boolean, ByVal timeout As Double, ByVal Value As Long, ByRef reserved As Any) As Long
In addition I'm a little concerned at the overheads in setting up "tasks" (as a loing-time writer of multi-tasking operating systems the appropriation of that term grates on me!) in NIDAQmx, on my test system the first time a task is set up seems to take 10 seconds or more, thrashing away on the disk. Admittedly the test system is slow and under resourced (64MB RAM and 300MHz processor), but the idea is that if the application runs on that it will do much better on a production machine. The Traditional code runs fine on the older hardware, however.
Cheers,
David