Take a look at the
NetGetJoinInformation function; I think it'll do what you need. You give it the name of the computer to query, and it gives you a string containing the domain or workgroup it belongs to, as well as a flag telling you which it was (domain/workgroup).
>Has anyone had any luck getting the workgroup on a win2k computer. I've looked at some examples in a previous thread about using the windows scripting host but was only able to retrieve the domain and not the workgroup.
>
>I've also looked at the NetWkstaGetInfo api but havn't had much luck.
>
>Any ideas would be greatly appreciated.
>tia,
>Gray
Fatal error 182 while attempting to report error 182.