There is no way to pole for the number of current connections. What you could do is ignore the first update if it is not valid. If there is no connection then it returns that the item is an integer with a value of 0. You could check type with DS_GetDataType and value with DS_GetDataValue and ignore the update if the first update is a integer (type = 103) and has a value of 0.
If that doesn't work for you because the item actually is an integer and 0 is a valid potential value, then you could have another solution. You could have another dataSocket item that is used to store the number of writers connected and each time a writer connects is adds one to the value of that socket. Then your reader programs could check that DataSocket item to see if writers a
re connecte
Best Regards,
Chris Matthews
National Instruments