AnsweredAssumed Answered

Get Logged in User's computerName

Question asked by myusufk90 on Aug 17, 2017
Latest reply on Aug 18, 2017 by myusufk90

Hi there,

 

Has anyone come across an SLCM method that can capture the logged-in user's computer name or has anyone managed to develop a plug-in capable of doing just that?

 

I came across some javascript that utilizes the ActiveXObject in the code below but it only works if the user is logging on via Internet Explorer and that their Security settings are set to low. 

 

Code:

var network = new ActiveXObject('WScript.Network');
// Show a pop up if it works
alert(network.computerName);

 

 

Outcomes