Getting current computer name via script

codedude
Mega Expert

This might seem like an off the wall question, but is there a way to get the current computer name/ip address of the computer the user is logged into.

Example: Say Joe Blow is logged into Jane Doe's computer. Joe Blow then logs into his ServiceNow account. When he opens the form it will pull in Jane Doe's computer name and ip address since Joe Blow is logged into her computer.

Any advice on how this can be done via scripting or any other avenue?

Thanks

10 REPLIES 10

Anurag Tripathi
Mega Patron
Mega Patron

his is not possible using JavaScript. If it were possible, that would be a major security risk.


It is however possible from the server. The server can send the data to the client.


Another solution is to use an ActiveX plugin.


http://forums.asp.net/t/1490314.aspx?how+do+get+Client+Machnine+Name+through+Javascript


-Anurag

Robert Beeman
Kilo Sage

Have you looked at the "Help the Help Desk" tool that is included free with Servicenow?


Help the Help Desk - ServiceNow Wiki



It can automatically populate this information into the CMDB that you can use anywhere.


Yeah, I see that information now. My problem is, is that the user might not know what the computer name or users name of the computer they are using for me to accurately query that table... In the case of test machines, etc.


The app uses WMI to query the local computer and send it to your SN instance. The user does not need to know.