Solved A batch file to analyse MSINFO file & output

August 22, 2014 at 03:20:55
Specs: Windows 7
I was wondering how I can create a batch file that will go through multiple MSINFO files from various machines, look at the amount of total memory, available memory and output the result for every machine in the format: Name of the machine, amount of total memory, amount of available memory in a text file.


PS: all msinfo files will be saved on the same drive in the same directory.

message edited by NikoBelic

See More: A batch file to analyse MSINFO file & output

Report •

August 22, 2014 at 20:04:12
✔ Best Answer
I've assumed a ".txt" filename extension, which is probably wrong, so change that.
If the file is "nfo", use "type" to convert to text.
:: begin batch
@echo off & setlocal enabledelayedexpansion
::change extension in following to suit
for /f %%a in (*.txt) do (
find /i "system name:" "%%a" >> report
find /i "physical memory" "%%a" >>report

Report •
Related Solutions

Ask Question