Detect empty parameters in ToolValidator?

729
2
12-07-2011 08:25 AM
JamesHook
New Contributor II
This may be a dumb question, but how do you determine in the ToolValidator class whether an input parameter has been left blank?

Some of the parameters in my tool are optional in some cases, and required in others.  I would like to raise an error when a field is left blank under certain circumstances.
Tags (2)
0 Kudos
2 Replies
LoganPugh
Occasional Contributor III
if not self.params[0].value:
   <add some error message>
0 Kudos
JamesHook
New Contributor II
Thanks for your help!
0 Kudos