Check variable for NULL batch

November 12, 2009 at 16:12:10
Specs: Windows XP
Hi, assuming this:

set missing=
...
if somecondition set missing somedata

How can I check if missing is empty?


See More: Check variable for NULL batch

Report •


#1
November 12, 2009 at 17:03:28
Modern batch scripting allows this:

if not defined missing set missing=data

In most cases it's also possible to use:

if "%missing%"=="" set missing=data


Batch Variable how to


Report •

#2
November 12, 2009 at 19:48:52
thank you

Report •

Related Solutions


Ask Question