When you go to "MyComputer " and get properties and select "Computer Name",
you get the Domain or Workgroup a computer belongs to.
I have looked thru MSDN library, the Internet, the Registry and in all files
on my computer and cannot find how to retrieve this information in VB.Net
2005.
This information is essential for our system implementation.
I have tried:
NetworkInformat ion.IPGlobalPro perties.GetIPGl obalProperties
but it does not get the info for a 'workgroup', only a 'domain'.
I have also tried:
SystemInformati on.UserDomainNa me
but still get nothing but the computer name if it is in a workgroup.
--
Steve
Microsoft Certified Partner 6 7684
try here http://www.planet-source-code.com/vb...4560&lngWId=10
--
Regards
John Timney
Microsoft MVP
"Spyder" <Sp****@discuss ions.microsoft. com> wrote in message
news:42******** *************** ***********@mic rosoft.com... When you go to "MyComputer " and get properties and select "Computer Name", you get the Domain or Workgroup a computer belongs to. I have looked thru MSDN library, the Internet, the Registry and in all files on my computer and cannot find how to retrieve this information in VB.Net 2005.
This information is essential for our system implementation. I have tried: NetworkInformat ion.IPGlobalPro perties.GetIPGl obalProperties but it does not get the info for a 'workgroup', only a 'domain'. I have also tried: SystemInformati on.UserDomainNa me but still get nothing but the computer name if it is in a workgroup.
-- Steve Microsoft Certified Partner
The app returned the computer's name on the pc that is just part of a
workgroup.
On my dev machine, it returned the domain name.
--
Steve
Microsoft Certified Partner
"John Timney ( MVP )" wrote: try here
http://www.planet-source-code.com/vb...4560&lngWId=10
-- Regards
John Timney Microsoft MVP
"Spyder" <Sp****@discuss ions.microsoft. com> wrote in message news:42******** *************** ***********@mic rosoft.com... When you go to "MyComputer " and get properties and select "Computer Name", you get the Domain or Workgroup a computer belongs to. I have looked thru MSDN library, the Internet, the Registry and in all files on my computer and cannot find how to retrieve this information in VB.Net 2005.
This information is essential for our system implementation. I have tried: NetworkInformat ion.IPGlobalPro perties.GetIPGl obalProperties but it does not get the info for a 'workgroup', only a 'domain'. I have also tried: SystemInformati on.UserDomainNa me but still get nothing but the computer name if it is in a workgroup.
-- Steve Microsoft Certified Partner
I think if your not logged into a domain, you will only get the computer
name - is your dev machine in a domain?
--
Regards
John Timney
Microsoft MVP
"Spyder" <Sp****@discuss ions.microsoft. com> wrote in message
news:53******** *************** ***********@mic rosoft.com... The app returned the computer's name on the pc that is just part of a workgroup. On my dev machine, it returned the domain name.
-- Steve Microsoft Certified Partner
"John Timney ( MVP )" wrote:
try here
http://www.planet-source-code.com/vb...4560&lngWId=10
-- Regards
John Timney Microsoft MVP
"Spyder" <Sp****@discuss ions.microsoft. com> wrote in message news:42******** *************** ***********@mic rosoft.com... > When you go to "MyComputer " and get properties and select "Computer > Name", > you get the Domain or Workgroup a computer belongs to. > I have looked thru MSDN library, the Internet, the Registry and in all > files > on my computer and cannot find how to retrieve this information in > VB.Net > 2005. > > This information is essential for our system implementation. > I have tried: > NetworkInformat ion.IPGlobalPro perties.GetIPGl obalProperties > but it does not get the info for a 'workgroup', only a 'domain'. > I have also tried: > SystemInformati on.UserDomainNa me > but still get nothing but the computer name if it is in a workgroup. > > > -- > Steve > Microsoft Certified Partner
The computers I need the workgroup name from are not part of a domain.
I can clearly see the name in the properties dialog box, so, I know it's
somehow set on the computer. I just have found no way to retrieve it.
--
Steve
Microsoft Certified Partner
"John Timney ( MVP )" wrote: I think if your not logged into a domain, you will only get the computer name - is your dev machine in a domain?
-- Regards
John Timney Microsoft MVP
"Spyder" <Sp****@discuss ions.microsoft. com> wrote in message news:53******** *************** ***********@mic rosoft.com... The app returned the computer's name on the pc that is just part of a workgroup. On my dev machine, it returned the domain name.
-- Steve Microsoft Certified Partner
"John Timney ( MVP )" wrote:
try here
http://www.planet-source-code.com/vb...4560&lngWId=10
-- Regards
John Timney Microsoft MVP
"Spyder" <Sp****@discuss ions.microsoft. com> wrote in message news:42******** *************** ***********@mic rosoft.com... > When you go to "MyComputer " and get properties and select "Computer > Name", > you get the Domain or Workgroup a computer belongs to. > I have looked thru MSDN library, the Internet, the Registry and in all > files > on my computer and cannot find how to retrieve this information in > VB.Net > 2005. > > This information is essential for our system implementation. > I have tried: > NetworkInformat ion.IPGlobalPro perties.GetIPGl obalProperties > but it does not get the info for a 'workgroup', only a 'domain'. > I have also tried: > SystemInformati on.UserDomainNa me > but still get nothing but the computer name if it is in a workgroup. > > > -- > Steve > Microsoft Certified Partner
Theres a post here from another MVP that should help you, it uses the
Management namespace and WMI, so its a better example.
Give that a try http://www.pcreview.co.uk/forums/thread-1225748.php
Regards
John Timney
Microsoft MVP
"Spyder" <Sp****@discuss ions.microsoft. com> wrote in message
news:DF******** *************** ***********@mic rosoft.com... The computers I need the workgroup name from are not part of a domain. I can clearly see the name in the properties dialog box, so, I know it's somehow set on the computer. I just have found no way to retrieve it.
-- Steve Microsoft Certified Partner
"John Timney ( MVP )" wrote:
I think if your not logged into a domain, you will only get the computer name - is your dev machine in a domain?
-- Regards
John Timney Microsoft MVP
"Spyder" <Sp****@discuss ions.microsoft. com> wrote in message news:53******** *************** ***********@mic rosoft.com... > The app returned the computer's name on the pc that is just part of a > workgroup. > On my dev machine, it returned the domain name. > > -- > Steve > Microsoft Certified Partner > > > "John Timney ( MVP )" wrote: > >> try here >> >> http://www.planet-source-code.com/vb...4560&lngWId=10 >> >> -- >> Regards >> >> John Timney >> Microsoft MVP >> >> "Spyder" <Sp****@discuss ions.microsoft. com> wrote in message >> news:42******** *************** ***********@mic rosoft.com... >> > When you go to "MyComputer " and get properties and select "Computer >> > Name", >> > you get the Domain or Workgroup a computer belongs to. >> > I have looked thru MSDN library, the Internet, the Registry and in >> > all >> > files >> > on my computer and cannot find how to retrieve this information in >> > VB.Net >> > 2005. >> > >> > This information is essential for our system implementation. >> > I have tried: >> > NetworkInformat ion.IPGlobalPro perties.GetIPGl obalProperties >> > but it does not get the info for a 'workgroup', only a 'domain'. >> > I have also tried: >> > SystemInformati on.UserDomainNa me >> > but still get nothing but the computer name if it is in a workgroup. >> > >> > >> > -- >> > Steve >> > Microsoft Certified Partner >> >> >>
That last link did the trick.
I am very VERY thankful to you, my friend.
--
Steve
Microsoft Certified Partner
"John Timney ( MVP )" wrote: Theres a post here from another MVP that should help you, it uses the Management namespace and WMI, so its a better example.
Give that a try
http://www.pcreview.co.uk/forums/thread-1225748.php
Regards
John Timney Microsoft MVP
"Spyder" <Sp****@discuss ions.microsoft. com> wrote in message news:DF******** *************** ***********@mic rosoft.com... The computers I need the workgroup name from are not part of a domain. I can clearly see the name in the properties dialog box, so, I know it's somehow set on the computer. I just have found no way to retrieve it.
-- Steve Microsoft Certified Partner
"John Timney ( MVP )" wrote:
I think if your not logged into a domain, you will only get the computer name - is your dev machine in a domain?
-- Regards
John Timney Microsoft MVP
"Spyder" <Sp****@discuss ions.microsoft. com> wrote in message news:53******** *************** ***********@mic rosoft.com... > The app returned the computer's name on the pc that is just part of a > workgroup. > On my dev machine, it returned the domain name. > > -- > Steve > Microsoft Certified Partner > > > "John Timney ( MVP )" wrote: > >> try here >> >> http://www.planet-source-code.com/vb...4560&lngWId=10 >> >> -- >> Regards >> >> John Timney >> Microsoft MVP >> >> "Spyder" <Sp****@discuss ions.microsoft. com> wrote in message >> news:42******** *************** ***********@mic rosoft.com... >> > When you go to "MyComputer " and get properties and select "Computer >> > Name", >> > you get the Domain or Workgroup a computer belongs to. >> > I have looked thru MSDN library, the Internet, the Registry and in >> > all >> > files >> > on my computer and cannot find how to retrieve this information in >> > VB.Net >> > 2005. >> > >> > This information is essential for our system implementation. >> > I have tried: >> > NetworkInformat ion.IPGlobalPro perties.GetIPGl obalProperties >> > but it does not get the info for a 'workgroup', only a 'domain'. >> > I have also tried: >> > SystemInformati on.UserDomainNa me >> > but still get nothing but the computer name if it is in a workgroup. >> > >> > >> > -- >> > Steve >> > Microsoft Certified Partner >> >> >> This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Shannon McMillan |
last post by:
Hey,
I want to change the name and workgroup/domain of a
computer at first boot prior to winlogon. I've written
code that will successfully change the computer's name and
workgroup/domain, but I'm having problems trying to work
out how this may then be implemented prior to a user
logging on. Any suggestions would be greatly appreciated.
Thanks,
|
by: Eka Gautama |
last post by:
Hi All,
How to retrive computer list in a workgroup?
Regards
Eka
|
by: Mark |
last post by:
I have a server in a workgroup (called "wg"). Does anyone know how to find
the name of the workgroup from code (pref c#)? I've trawled the newsgroups
and the MSDN site for the right class / method / property to use but I just
can't find the right one. There are plenty (such as UserDomainName) that
give me the server name, but none that I can find to give me the actual
workgroup name.
TIA
Mark
|
by: Gonçalo Boléo |
last post by:
How can i get the name of my computer?
Is there any class that gives me access to properties like ComputerName,
Workgroup, Domain?
thnaks,
Gonçalo Boléo
|
by: Manoj |
last post by:
Hi,
How can we get info as to if a terminal is on a workgroup or a domain and
the name of the domain\workgroup in windows 2000 professional through code
thanks in advance
Manoj
| |
by: Frederik |
last post by:
Hi all,
Situation:
- 2 computers behind router/switch
- dhcp enabled on router
- computer name 1 = cpuA (WinXP Pro)
- computer name 2 = cpuB (WinXP Home)
- cpuA and cpuB can access each other's resources
- cpuA runs IIS with asp.net website
|
by: John |
last post by:
Tried this on microsoft.public.access.gettingstarted - no response -
perhaps more appropriate here.
I'm not a database user, simply helping someone get started with a new
computer.
The old computer (win98se) runs a database in MS Access 97 pro, with
all the attendant permissions etc. I can work on the database without
problems, once I've opened the file with the requisite user name and
|
by: schaf |
last post by:
Hi all!
I'm still trying to start/stop a service on a remote computer. (I
promiss that's the last new post because of this problem from my side)
My situation:
I've an application running under the user paul (pw:paul123) on the
computer A in the domain ABC. This application should stop / start a
service, which is running on computer B (in workgroup ABCWG (NOT IN
DOMAIN ABC)). On the computer B I have a user administrator (pw:
adminTest)...
|
by: AnuSumesh |
last post by:
Hi All,
I want code for :
whether server is in workgroup or in domain and then i want to get the workgroup/domian name of server.
I am using c#. I know the code for getting domain name but how to get workgroupname?
Can anyone help me plz?
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
| |
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols.
I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
| |
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |