Windows 8 computers can't iterate through workgroup members?

I am having a problem getting the list of computers in my workgroup from Windows 8 (x64) system.

There are several computers in my workgroup, some with W7 and some with W8. W7 computers can get a list of all workgroup PCs, while W8 computers cannot (no result, even the PC running the code) with the same code.

using (DirectoryEntry workgroup = new DirectoryEntry("WinNT://Workgroup"))
    {
        foreach (DirectoryEntry childEntry in workgroup.Children)
        {
            Console.WriteLine(childEntry.Name);
        }
    }

      

I tried using the solutions given here: Get computers in a workgroup

Anyone have an idea about this?

: Visual Studio runs as administrator for this

+3


source to share


1 answer


Start Visual Studio or the executable file that it created as an administrator.



If the point is that you are already using VS / exe as administrator, make sure the W8 machines are in the same workgroup called "WORKGROUP" and that they are not Windows RT (Windows on ARM) because they do not support working groups.

+2


source







All Articles