By registering with us, you'll be able to discuss, share and private message with other members of our community.

SignUp Now!

How to? A very simple question re. the current line number in a batch file...

Is there any way to get the line number of the currently executing statement in a batch file? Something like "blah blah blah error on line 25 in batch file abcdef", for instance. I was thinking something like an internal variable ("%_LineNumber", for example) but searching the docs I'm not finding anything...

- Dan
Thank you, Steve, I'm laughing as I type this!:) I figured it was something as simple as that but I honestly would never have guessed "_batchline". Makes total sense in hindsight, however. Thanks again!

Similar threads