Scott, I'm a little bit surprised that you took the time to do that because of course I knew that but I just didn't take the time to state what I thought was obvious - if if there is no parameter 1 (at all, as opposed to an "empty" parameter 1, however you decide to allow that to be coded/how it is specified), then, by definition, there is no parameter 2, no parameter3, ...; there are no parameters at all. As far as back quotes go, I knew that but I tend to prefer the use of the plain old double quotes for whatever reason(s) - maybe my finger knows where they are without me really having to think about it; and the whole situation involved doesn't come up often enough (for me, at any rate) to be an issue. And, I will note, if the expression testing for the existence of parameter 1 is "%@UnQuoteS[%1]" == "" (the bold font is to avoid the issue of (double) quoting a string that contains double quotes in the context of these postings) coding either "" or `` works equally well. (There are no situations in my batch files where an empty doubly-quoted string would be expected/valid - although code I write does not assume that if the above test comes up true that there are no further positional parameters (see the last point in this posting) - the previous would then be reported as an error in some manner; and as a general rule I use what were at least once known as keyword parameters in these kinds of situations: /paramtername...whatever. When a parameter may be "missing", it shouldn't be a "positional" parameter in the first place as far as I am concerned.) Finally, in those situations where I am iterating through the parameters, I always use the "construction" Do While %# != 0 (with, of course, a Shift in the loop), and the test "%@UnQuoteS[%1]" == "" meets my needs perfectly.
- Dan