Thursday 14 June 2012

Get Mac address of your computer in vb.net?



Get Mac address of your computer 

What is Mac(Media Access Control) more details wiki
Get software to change Mac Address your computer Mac
To get Mac address of your do like this
One button
Copy the code below
ImportsSystem.Net.NetworkInformation

Public Class Form1

    Private Sub Button1_Click(ByValsender As System.Object, ByVal e AsSystem.EventArgs) HandlesButton1.Click
        Try
            ForEach nic AsSystem.Net.NetworkInformation.NetworkInterfaceIn System.Net.NetworkInformation.NetworkInterface.GetAllNetworkInterfaces
                MessageBox.Show(String.Format("the mac address of {0} is{1}{2}", nic.Description, Environment.NewLine, nic.GetPhysicalAddress()))
            Next
        Catchex As Exception
            MessageBox.Show(ex.Message.ToString)
        End Try
    End Sub


End Class