I'm working on a project with a similar need.
It isn't impossible, but the "enumerate the items at this DS URL" part is hidden from the programmer.
The datasocket ActiveX library can be called directly in whatever programming environment you want (LabVIEW, Visual Studio) by pointing at CWDSLib. When you call CWDSLib's select(), a NInetbrowser (BROWSERLib) is built, the URLs are retrieved through NILogosxt prestidigitation, and then the browser is presented to the user. I've spent a little time watching this with procmon, Ollydbg and wireshark, but haven't been able to put all the pieces together yet.
In the end, I expect the process to be a series of hacky calls to nids.dll and nilxtcor.dll.