In order to do this, you need to internally route the counter's output signal to trigger the analog input task. This looks like the code below.
- Insert the DAQmx Trigger VI into your block diagram and choose the Reference Digital Edge option.
- Right click on the edge input and select Create >> Constant. Change this constant to the rising or falling edge.
- Right click the source input and select Create >> Constant.
- Right click the newly created source constant and select I/O Name Filtering...
- In the Filter Names dialog, check Include Advanced Terminals and click OK.
- Click within the source constant and scroll down. In the list, there should be /device/CtrXInternalOutput. Select the internal output that corresponds to the counter used in the counter task.
- Insert a DAQmx Trigger Property Node. Select the property Reference >> More >> Retriggerable.
- Wire a true constant to the Ref.Retriggerable Property.