For a DAQmx device, you can use a property node. See attached example.
Functions palette >> Measurement I/O (or NI Measurements for LV7) >> DAQmx - Data Acquisition >> DAQmx Advanced >> System Setup >> DAQmx Device Property Node
Put the property node on the diagram >> resize it to add a property
Click on the lower property >> Identification >> Device Serial Number
Wire the device to the ActiveDev property andan indicator to DevSerialNum. The serial number is a hexadecimal value and therefore you should set the string indicator to hexadecimal.