|So I was thinking that I would like to combine a little of yesterday's post with another command. Here is what I would like to try to accomplish...|
Take the ldifde output after the computer names are parsed, ping them once and if there is a reply from the remote computer, reg query them for a specific software.
Here is what I have so far, but don't know how to combine the two correctly.
This will ping each machine in my text file and output the name and IP to a CSV file...
Echo Computername,IP Address>Final.csv
for /f "usebackq tokens=*" %%A in ("%ComputerList%") do (
for /f "tokens=3" %%B in ('ping -n 1 -l 1 %%A ^|findstr Reply') do (
I would like to add either command to the file...I just want to run the below command on responding computers...it would be great if I could run this scan over and over and append to the bottom of the CSV since machines may be on at different times of the day.
reg query \\computername\HKLM\Software\Lotus\Notes /v Version
or WMIC /Node:%ComputerName% product where "Name like '%Lotus%'" get Name, Version
Thanks for any support!