Check a multivalue field in a table and prompt based on a certain value

I have the following code below in a table with a lookup to a view capturing multivalue fields (line items). I need to be able to prompt the user when the UN_Status field value is “Rented - Sold”. However, my prompt is not working properly…it works sometimes with the correct value, then will only work once or work on all statuses. Can someone please help me? Thanks in advance

@If(((TR_EquipData != “”) & (TR_MoveType = “Single Unit Move”)); @Return(@Prompt([Ok]; “Error”; “You can only enter one unit for a single unit move type.”)); @Success);

FileName := @Left(@UpperCase(@Subset(@DbName; -1)); @UpperCase(“Global_Transport.nsf”)) + “GlobalUnits.nsf”;

strNewEquip := @PickList([Custom] : [Single]; @Subset(@DbName; 1) : FileName; “HIDEquipforTransport”; “Choose Unit”; “Choose a unit from the list below.”;7);

@If(strNewEquip = “”; @Return(“”); @Success);

strHitch := @Prompt([OkCancelList]; “Pintle Hitch?”; “Does the equipment have a printle hitch?”; “Uncertain”; “Uncertain” : “Yes” : “No”);

FIELD TR_EquipData := @If(TR_EquipData != “”; @Explode((strNewEquip + "; " + @Implode(TR_EquipData; “^”)); “^”); strNewEquip);

FIELD TR_PintleHitch := @If(TR_PintleHitch != “”; @Explode((strHitch + "; " + @Implode(TR_PintleHitch; “|”)); “|”); strHitch);

@If(@Contains(UN_Status ;“RENTED - SOLD”);@Prompt([YesNo]; “SOLD UNIT?”; “You have selected a SOLD unit. Would you like to continue? If your answer is NO, please use the Delete Equipment button above to remove the unit”);@Success);

@Command([ViewRefreshFields])

Subject: Check a multivalue field in a table and prompt based on a certain value

FIGURED IT OUT! Replace with the line of code below

@If(@Contains(strNewEquip ;“RENTED - SOLD”);@Prompt([YesNo]; “SOLD UNIT?”; “You have selected a SOLD unit. Would you like to continue? If your answer is NO, please use the Delete Equipment button above to remove the unit”);@Success);