Link to home
Start Free TrialLog in
Avatar of Steve4400
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.
Avatar of Paolo Santiangeli
Paolo Santiangeli
Flag of Italy image

ASKER CERTIFIED SOLUTION
Avatar of oBdA
oBdA

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Steve4400
Steve4400

ASKER

Worked!  Thanks very much.