What is the command to display computer name & ip address in VB.NET 2005 (OS
WindowsXP & Windows Vista)
Regards,
Tee 5 3732
"Eng Teng" <en*****@gmail. comschrieb
What is the command to display computer name & ip address in VB.NET
2005 (OS WindowsXP & Windows Vista)
Environment.Mac hineName or SystemInformati on.Computername , and http://groups.google.com/group/micro...d407946e79f801
Armin
On May 2, 3:48 pm, "Eng Teng" <engt...@gmail. comwrote:
What is the command to display computer name & ip address in VB.NET 2005 (OS
WindowsXP & Windows Vista)
Regards,
Tee
Hi Eng,
For short ways,
' To display computer name:
My.Computer.Inf o.OSFullName
' To display local IP:
Imports System.net
Module Module1
Sub Main()
'To get local address
Dim sHostName As String
Dim i As Integer
sHostName = Dns.GetHostName ()
Dim ipE As IPHostEntry = Dns.GetHostByNa me(sHostName)
Dim IpA() As IPAddress = ipE.AddressList
For i = 0 To IpA.GetUpperBou nd(0)
Console.Write(" IP Address {0}: {1} ", i, IpA(i).ToString )
Next
Console.ReadLin e()
End Sub
End Module
Hope this helps,
Onur Güzel
How about Service Pack info ?
"kimiraikko nen" <ki************ *@gmail.comwrot e in message
news:c3******** *************** ***********@24g 2000hsh.googleg roups.com...
On May 2, 3:48 pm, "Eng Teng" <engt...@gmail. comwrote:
What is the command to display computer name & ip address in VB.NET 2005
(OS
WindowsXP & Windows Vista)
Regards,
Tee
Hi Eng,
For short ways,
' To display computer name:
My.Computer.Inf o.OSFullName
' To display local IP:
Imports System.net
Module Module1
Sub Main()
'To get local address
Dim sHostName As String
Dim i As Integer
sHostName = Dns.GetHostName ()
Dim ipE As IPHostEntry = Dns.GetHostByNa me(sHostName)
Dim IpA() As IPAddress = ipE.AddressList
For i = 0 To IpA.GetUpperBou nd(0)
Console.Write(" IP Address {0}: {1} ", i, IpA(i).ToString )
Next
Console.ReadLin e()
End Sub
End Module
Hope this helps,
Onur Güzel
On May 2, 6:24 pm, "Eng Teng" <engt...@gmail. comwrote:
How about Service Pack info ?
"kimiraikko nen" <kimiraikkone.. .@gmail.comwrot e in message
news:c3******** *************** ***********@24g 2000hsh.googleg roups.com...
On May 2, 3:48 pm, "Eng Teng" <engt...@gmail. comwrote:
What is the command to display computer name & ip address in VB.NET 2005
(OS
WindowsXP & Windows Vista)
Regards,
Tee
Hi Eng,
For short ways,
' To display computer name:
My.Computer.Inf o.OSFullName
' To display local IP:
Imports System.net
Module Module1
Sub Main()
'To get local address
Dim sHostName As String
Dim i As Integer
sHostName = Dns.GetHostName ()
Dim ipE As IPHostEntry = Dns.GetHostByNa me(sHostName)
Dim IpA() As IPAddress = ipE.AddressList
For i = 0 To IpA.GetUpperBou nd(0)
Console.Write(" IP Address {0}: {1} ", i, IpA(i).ToString )
Next
Console.ReadLin e()
End Sub
End Module
Hope this helps,
Onur Güzel
To get Service Pack version,
simply use;
Environment.OSV ersion.ServiceP ack
Hope this helps,
Onur Güzel http://msdn.microsoft.com/en-us/library/aa394582.aspx
"Eng Teng" <en*****@gmail. comschreef in bericht
news:%2******** ********@TK2MSF TNGP05.phx.gbl. ..
How about Service Pack info ?
"kimiraikko nen" <ki************ *@gmail.comwrot e in message
news:c3******** *************** ***********@24g 2000hsh.googleg roups.com...
On May 2, 3:48 pm, "Eng Teng" <engt...@gmail. comwrote:
>What is the command to display computer name & ip address in VB.NET 2005 (OS WindowsXP & Windows Vista)
Regards, Tee
Hi Eng,
For short ways,
' To display computer name:
My.Computer.Inf o.OSFullName
' To display local IP:
Imports System.net
Module Module1
Sub Main()
'To get local address
Dim sHostName As String
Dim i As Integer
sHostName = Dns.GetHostName ()
Dim ipE As IPHostEntry = Dns.GetHostByNa me(sHostName)
Dim IpA() As IPAddress = ipE.AddressList
For i = 0 To IpA.GetUpperBou nd(0)
Console.Write(" IP Address {0}: {1} ", i, IpA(i).ToString )
Next
Console.ReadLin e()
End Sub
End Module
Hope this helps,
Onur Güzel
This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Maverick |
last post by:
I'm trying to get the " Computer Name " of a client accessing my web
site,
is there a way to do this ? not ip...
tia
|
by: JayPee |
last post by:
Here is my dilema. I'm running IIS on a Windows 2000 Proffessional PC.
I'm a running a small intranet site off this machine which is
accessible by the end users by typing in the computer name of this
machine. What I need is a script of any kind that will allow me to
capture the end users internal IP address and display it on the status
bar of their IE window (Bottom left). Again, the only people accessing
this site are internal users and I...
|
by: Sweety |
last post by:
plz reply,
thanks in advance.
bye
|
by: Uzi Baruch |
last post by:
Hi!
i want to know if i have an ip address of a computer and its DNS server
name, if their is an windows API
that can resolve the computer name of the given ip address.
or vice verca - given a computer name and it's DNS server, i need to obtain
the IP address.
|
by: Dan Nash |
last post by:
Heylo
I want to be able to get the computer name from my C# page. Is this
possible? Basically, I'm developing a auto-bugreport feature for an intranet
and want to know which machine sent the report. All machines are listed on
the workgroup and in AD.
Any suggestions?
Cheers
| |
by: Paul Bromley |
last post by:
Thanks for your tolerance on this list. I asked the question regarding
Commercial Copy Protection along with Unique PC Idnetifier and obtaining the
active IP address. This was all to identify and tie down software to each PC
on a network. I have just realised that the unique identity that I need to
go for on the network and should be easy to get in a foolproof manner is the
computer name. Hence which method will ALWAYS return the computer...
|
by: ajays |
last post by:
I want to get the full computer name using the ActiveState Perl on windows .
Actually i can get that using the "hostname" command, but i want to have the output of the "hostname" command stored in some variable using perl. And i wan to use that variable in my script.
Is it possibel to write a script which will store the return value of the command executed on the command prompt and how ???
Kindly help
|
by: kartik369 |
last post by:
This code gets the IP address from the computer name we already know. I wanted to know how can we get the computer name if we know the IP address. Thanks
void AsyncServer::InitSocks()
{
String* server = "CATUXPSD01";
int port = 4901;
printf("in InitSocks");
String* request = String::Concat(S"Our test data asdf");
|
by: need2know |
last post by:
Just purchased a dell system and compleated the set up process. I am concerned though. On the enter computer name and administrator password screen i entered a password. I thought it would have been the password i woud use to log in but it doesnt have a log in screen.
What is the password for???
Can i remove it?
Also when i right click on my computer and select properties and it takes me to the system properties screen and when i click...
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look !
Part I. Meaning of...
|
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: 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: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
|
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: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
|
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |
by: bsmnconsultancy |
last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...
| |