Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to add more than one condition in a propertygroup?

I have a property right now that looks like this.

<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|iPhoneSimulator' ">

I now want to add another Condition in there looking like this:

Condition=" '$(SolutionFileName)' == 'SolutionName.AppNameOne.sln'"

How do I add more than one condition inside this propertygroup?

like image 536
Carlos Rodrigez Avatar asked Dec 14 '17 08:12

Carlos Rodrigez


1 Answers

I found the answer. You use "AND" to use multiple conditions: https://social.msdn.microsoft.com/Forums/vstudio/en-US/dc1f3f61-3aeb-41df-877a-51e300964522/how-to-add-multiple-condition-in-the-condition-statement?forum=msbuild

Example: Condition = " '$(BuildBreak)'!='true' AND '$(XYZ)' == 'ABC' "

like image 58
Carlos Rodrigez Avatar answered Nov 02 '22 01:11

Carlos Rodrigez