>I know that you found the answer, but I thought I would throw this out for you (and anyone else) anyway. Try looking up the API fuction
NetServerEnum. It will list all servers of the specified type that are visible in a domain. I'm pretty sure that this is what all of the SQL Server applications you are refering to use also. It will not show hidden servers, which is what I have witnessed with the SQL application on our domains.
>
Not a good choice; it only works under NT/2K, and will return a NetAPIBuffer that you have to parse yourself, and explicitly release after extraction of the embedded list of SERVER_INFO_101 structures (they contain UniCode strings as well, a separate issue) otherwise the underlying OS resources will bleed. The same services are available with a whole lot less effort on a cross-platform basis using ADSI, or using enumeration through WNetEnumResources (my NETRSC class contains sample code to enumerate all resources of all types using this API call.)