I have like 5000 computers in my active directory and I need to put on the computer description (in active directory) the logged user and the computer model. I know that there is a WMI script that allow to do this but dunno how to make it.
I have a .BAT script that updates the user name but I think that in order to use it I need to use .vsb script.
this is the script I have
for /f "delims=" %%a in ('dsquery computer -name "%Machine%"') do set MachineDN=%%a
dsmod computer %MachineDN% -desc %Description%
I am giving 500 points as I need to do this assap or my boss is gonna kill me. Thanks