The DAQmx driver automatically performs the double buffering for continuous digital input operations. Therefore, there is no extra programming/functions needed for this operation. You will only need a continuous digital input application.
I found a continuous digital input example configured for an external clock. Here is the link: C:\Program Files\National Instruments\NI-DAQ\Examples\DAQmx ANSI C\Digital\Read Values\Cont Read Dig Chan-Ext Clk. You will have to make some modifications which are documented in the NI-DAQmx C API Visual Basic 6.0 Help which is located in Start >> All Programs >> National Instruments >> NI-DAQ.
Here is the link to a tutorial which has some useful information about the DAQmx driver: Answers to Frequently Asked Questions about NI-DAQmx and Traditional NI-DAQ (Legacy). I hope that you find this information helpful.