Get Help:Ask a Question in our Forums|Report a Bug|More Help Resources
Last post Sep 01, 2009 05:18 PM by Ram Reddy Mekha
Sep 01, 2009 05:59 AM|LINK
Good Morning Friend
how To Get Client MacAddress. this is basically for validate user for login.
Sep 01, 2009 06:14 AM|LINK
This sample code shows how to retrieve the MAC address of your computer using C#.
public string GetMACAddress()
ManagementClass mc = new ManagementClass("Win32_NetworkAdapterConfiguration");
ManagementObjectCollection moc = mc.GetInstances();
string MACAddress = String.Empty;
foreach (ManagementObject mo in moc)
if (MACAddress == String.Empty) // only return MAC Address from first card
if ((bool)mo["IPEnabled"] == true) MACAddress = mo["MacAddress"].ToString();
MACAddress = MACAddress.Replace(":", "");
Sep 01, 2009 06:39 AM|LINK
Thanks for reply me
Sorry To say, but i think i getting server Mac address
i have checked it offline or online both.
i mean where my site is opening and just checking is my pc mac address or another pc so do
do u have another
Sep 01, 2009 06:48 AM|LINK
i think u can not get the client mac address untill u r using windows authentication. The code posted here wud work if u run the code on local development server but on IIS, it wont work.
Sep 01, 2009 05:18 PM|LINK
Hope the discussion on the same at here will help you.