How to identify if system is a server or workstation

Status
Not open for further replies.
G

Guest

Guest
Hello,
how do i get a C# code to differentiate between the server and a workstation
 

Ijack

Distinguished
Check the Registry Key "HKEY_LOCAL_MACHINE\System\CurrentControlSet\ControlProductOptions\ProductTy
pe". For a workstation this should have the value "WinNT". For a server it will be something else (options used to be "ServerNT" and "LanmanNT", but it's possible they may be different now).
 

saint19

Distinguished
Mar 20, 2009
270
0
19,060
Hi newcomer and welcome to the Tom's hardware forum.

Well, has been a long time since my last program, but lets see.

You need a program that call the specific file that ijack says, and compared this file with a definition that you can made, for example

....if (a==b)
{
cout<<"You have a Workstation";
}
else if
{
cout<<"You have a server station";
}

a & b are char

I think that is something like this, like i said, has been a long time since my last program. Review the structure and syntax and start to do the program.
 
Status
Not open for further replies.

TRENDING THREADS