Steve4400
asked on
Running total in a DOS loop
I am having trouble creating a running total in a DOS loop.
this is what I have inside the loop:
set total=%%H
set /a tot=%total%+%%H
echo. %tot%
total is initalized to zero
my results look like:
0+2346
0+4524
0+3987 ect.
Any help would be greatly appreciated. Thanks.
this is what I have inside the loop:
set total=%%H
set /a tot=%total%+%%H
echo. %tot%
total is initalized to zero
my results look like:
0+2346
0+4524
0+3987 ect.
Any help would be greatly appreciated. Thanks.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Worked! Thanks very much.
did you look here?
https://www.experts-exchange.com/questions/23956059/sum-numbers-in-text-file-in-batch.html