I'm just starting with batch files, and I'm trying to loop over my Path environment variable with this script:
for %%A in %PATH% do echo %%A
ant I'm getting the error in the title.
While running set
I see that path has a value, and the "c:\ant-1.8.4\bin" is what I'm looking for.
I tried playing around with it, and even this:
for %%A in %PATH% do echo TEST
fails with the same error.
Thanks!
edit - clarification In the end, I want to do a small manipulation on each entry, so Magoo's answer doesn't really solve the problem for me.