|
#1
|
|||
|
|||
Conditional build step (multiple conditions)
Hi,
I've been struggling with this for the past few hours, and I figure I'll ask the group. I've got a build step that I only want to build when 'arg1' and 'arg2' are both set to false (so essentially a NOR statement) I've tried the expression as: [%arg1%] NOR [%arg2%] (drop down = is true) Also: %arg1% NOR %arg2% (drop down = is true) When I run the build file, the group gets executed when Arg1 = 1/True, and ignores whatever Arg2 is set to. I'm using v6.1 at the moment. (ps: I've just tried changing the operator from NOR to AND, and the same occurs, it seems to ignore the Arg2 parameter). I'm sure that it's something simple that I"m forgetting to do... Thanks in advance! Eric. |
#2
|
|||
|
|||
Resolved:
[Application.FindMacro("arg1").Value = "False" AND Application.FindMacro("arg2").Value = "False"] works. Follow-up: Is there a less "convoluted" method of doing this? |
#3
|
|||
|
|||
It looks fairly straightforward to me. You can shorten it up a bit:
["%arg1%" = "False" And "%arg2%" = "False"] or [Not %arg1% And Not %arg2%] or [Not (%arg1% Or %arg2%)] |
#4
|
|||
|
|||
Is word for using "OR operator is OR...or pipe (||) ?
|
#5
|
|||
|
|||
In VBScript, OR is the logical OR operator. For other languages, it can be something else.
http://msdn.microsoft.com/en-us/libr...=vs.84%29.aspx |
|
|