I'm getting some Operator == cannot be applied to string and bool compile error with this:
Code: Select all
var isChecked = .Element.GetAttributeValueText("Checked");
var faxNo = BtnNo.Element.GetAttributeValueText("Checked");
var faxYes = BtnYes.Element.GetAttributeValueText("Checked");
switch(isChecked, faxYes)
{
case 1:
isChecked && faxYes == "False";
Report.Info("No faxes were sent");
break;
case 2:
isChecked && faxYes == "True";
Report.Info("Faxes were sent and match");
break;
case 3:
isChecked == False && faxTextField == True;
Report.Info("mismatch fail");
break;
case 4:
isChecked == True && faxTextField == False;
Report.Info("mismatch fail");
break;
}
Code: Select all
if(faxYes && isChecked == true)
{
Report.Info("both items match");
}
if(isChecked == faxYes)
{
Report.Info("The checkbox is not returning a value for is checked. The Item is matched");
}
if(isChecked == "True")
{
Report.Info("The CheckBox is returning true");
}