title: How to use values from two datacardvalue fields to disable an "action" button in powerapps
body: <p>I need to use the values in DataCardValue6 and DataCardValue7 from a detail form in Powerapps to disable a button given they both return a value of "NON-STOCK". The name of the field returned from  one of the fields in the SharePoint list  is AMC_ItemType, not sure if that matters at all as I was just looking at the value.</p>
  
  <p>I have been trying to do this in the rules area and disable the button given those values. Things I have tried</p>
  
  <p>(Value(DataCardValue6.Text) And Value(DataCardValue7.Text)) in "NON-STOCK". This for some reason is returning blanks when I check what the output of this is.</p>
  
  <p>(DataCardValue6.Text And DataCardValue7.Text) in "NON-STOCK". I have tried to split this into two equations, did not change outcome. I also tried to set it to equals "NON-STOCK" and it says right is a left is a Boolean and right is text.</p>
  
  <p>Is the best way to disable a button given the value in the two fields to use a rule attached to the button itself? Or should I be doing something in the onselect function? I also tried adding textboxes with the returned values and make rules against those, still no luck.</p>