Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Web Development
  3. ASP.NET
  4. How Can I retrive Client PC MAC address

How Can I retrive Client PC MAC address

Scheduled Pinned Locked Moved ASP.NET
csharpjavascripthtmlasp-nettools
7 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • K Offline
    K Offline
    krishnaveer
    wrote on last edited by
    #1

    Hi Guys I am working an asp.net application in which i required to fetch client PC MAC address I gone through this Script but its giving Error So Any Other solution Plz Tell me <html xmlns="http://www.w3.org/1999/xhtml"> <head> <title>Untitled Page</title> <script id="clientEventHandlersJS" type="text/javascript"> function Button1_onclick() { var locator = new ActiveXObject ("WbemScripting.SWbemLocator"); var service = locator.ConnectServer("."); var properties = service.ExecQuery("SELECT * FROM Win32_NetworkAdapterConfiguration"); var e = new Enumerator (properties); document.write("<table border=1>"); dispHeading(); for (;!e.atEnd();e.moveNext ()) { var p = e.item (); document.write("<tr>"); document.write("<td>" + p.Caption + "</td>"); document.write("<td>" + p.IPFilterSecurityEnabled + "</td>"); document.write("<td>" + p.IPPortSecurityEnabled + "</td>"); document.write("<td>" + p.IPXAddress + "</td>"); document.write("<td>" + p.IPXEnabled + "</td>"); document.write("<td>" + p.IPXNetworkNumber + "</td>"); document.write("<td>" + p.MACAddress + "</td>"); document.write("<td>" + p.WINSPrimaryServer + "</td>"); document.write("<td>" + p.WINSSecondaryServer + "</td>"); document.write("</tr>"); } document.write("</table>"); } function dispHeading() { document.write("<thead>"); document.write("<td>Caption</td>"); document.write("<td>IPFilterSecurityEnabled</td>"); document.write("<td>IPPortSecurityEnabled</td>"); document.write("<td>IPXAddress</td>"); document.write("<td>IPXEnabled</td>"); document.write("<td>IPXNetworkNumber</td>"); document.write("<td>MACAddress</td>"); document.write("<td>WINSPrimaryServer</td>"); document.write("<td>WINSSecondaryServer</td>"); document.write("</thead>"); } &

    C 1 Reply Last reply
    0
    • K krishnaveer

      Hi Guys I am working an asp.net application in which i required to fetch client PC MAC address I gone through this Script but its giving Error So Any Other solution Plz Tell me <html xmlns="http://www.w3.org/1999/xhtml"> <head> <title>Untitled Page</title> <script id="clientEventHandlersJS" type="text/javascript"> function Button1_onclick() { var locator = new ActiveXObject ("WbemScripting.SWbemLocator"); var service = locator.ConnectServer("."); var properties = service.ExecQuery("SELECT * FROM Win32_NetworkAdapterConfiguration"); var e = new Enumerator (properties); document.write("<table border=1>"); dispHeading(); for (;!e.atEnd();e.moveNext ()) { var p = e.item (); document.write("<tr>"); document.write("<td>" + p.Caption + "</td>"); document.write("<td>" + p.IPFilterSecurityEnabled + "</td>"); document.write("<td>" + p.IPPortSecurityEnabled + "</td>"); document.write("<td>" + p.IPXAddress + "</td>"); document.write("<td>" + p.IPXEnabled + "</td>"); document.write("<td>" + p.IPXNetworkNumber + "</td>"); document.write("<td>" + p.MACAddress + "</td>"); document.write("<td>" + p.WINSPrimaryServer + "</td>"); document.write("<td>" + p.WINSSecondaryServer + "</td>"); document.write("</tr>"); } document.write("</table>"); } function dispHeading() { document.write("<thead>"); document.write("<td>Caption</td>"); document.write("<td>IPFilterSecurityEnabled</td>"); document.write("<td>IPPortSecurityEnabled</td>"); document.write("<td>IPXAddress</td>"); document.write("<td>IPXEnabled</td>"); document.write("<td>IPXNetworkNumber</td>"); document.write("<td>MACAddress</td>"); document.write("<td>WINSPrimaryServer</td>"); document.write("<td>WINSSecondaryServer</td>"); document.write("</thead>"); } &

      C Offline
      C Offline
      Christian Graus
      wrote on last edited by
      #2

      What does 'it's giving error' mean ? That's kind of useless. As you're finding, you can only find the Mac address in IE, no other browser, and then only via an ActiveX control.

      Christian Graus Driven to the arms of OSX by Vista. Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.

      K 1 Reply Last reply
      0
      • C Christian Graus

        What does 'it's giving error' mean ? That's kind of useless. As you're finding, you can only find the Mac address in IE, no other browser, and then only via an ActiveX control.

        Christian Graus Driven to the arms of OSX by Vista. Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.

        K Offline
        K Offline
        krishnaveer
        wrote on last edited by
        #3

        Ya Its working only in ie 6.0 after Active ActiveX component but I want Script which work in all browser or Any different method i can use

        krishna veer singh

        N 1 Reply Last reply
        0
        • K krishnaveer

          Ya Its working only in ie 6.0 after Active ActiveX component but I want Script which work in all browser or Any different method i can use

          krishna veer singh

          N Offline
          N Offline
          N a v a n e e t h
          wrote on last edited by
          #4

          krishnaveer wrote:

          Any different method i can use

          No other alternatives.

          Navaneeth How to use google | Ask smart questions

          K 1 Reply Last reply
          0
          • N N a v a n e e t h

            krishnaveer wrote:

            Any different method i can use

            No other alternatives.

            Navaneeth How to use google | Ask smart questions

            K Offline
            K Offline
            krishnaveer
            wrote on last edited by
            #5

            So How can go ahead with this one becoz its my application requirement

            krishna veer singh

            N C 2 Replies Last reply
            0
            • K krishnaveer

              So How can go ahead with this one becoz its my application requirement

              krishna veer singh

              N Offline
              N Offline
              N a v a n e e t h
              wrote on last edited by
              #6

              You customer may not know about web applications. But as a programmer, you should be able to understand the limitations of a web application and take appropriate design decisions. As I said, there is no way to get clients MAC id. Try to make your customer understand this and think about other possible designs. BTW, what are you doing with the clients MAC id?

              Navaneeth How to use google | Ask smart questions

              1 Reply Last reply
              0
              • K krishnaveer

                So How can go ahead with this one becoz its my application requirement

                krishna veer singh

                C Offline
                C Offline
                Christian Graus
                wrote on last edited by
                #7

                If your client had approached a real programmer, then they would have dealt with someone who told them what was physically possible, instead of someone who accepted anything that they could imagine, despite having no idea how it could be done.

                Christian Graus Driven to the arms of OSX by Vista. Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.

                1 Reply Last reply
                0
                Reply
                • Reply as topic
                Log in to reply
                • Oldest to Newest
                • Newest to Oldest
                • Most Votes


                • Login

                • Don't have an account? Register

                • Login or register to search.
                • First post
                  Last post
                0
                • Categories
                • Recent
                • Tags
                • Popular
                • World
                • Users
                • Groups