Based on the value of a dropdown I set a variable named transTypeMode. This works fine.
If(TransTyepDD.Selected.Value="CycleCount", Set(transTypeMode,"Update"), TransTyepDD.Selected.Value="Receipt", Set(transTypeMode,"Addition"),TransTyepDD.Selected.Value="Issue", Set(transTypeMode,"Subtraction"))
I have two text boxes and a label. Based on the transTypeMode a calculation or update will occur.

I tested each condition of the if statement separately and each one works. When I combine all three statement into one it breaks. For the life of me I cannot see the reason why. I compared my syntax to the Microsoft If and Switch functions here and I still don't see the problem.
If (transTypeMode = "Update", TransQty, transTypeMode = "Addition", TransQty + QtyOnHand, transTypeMode = "Subtraction", QtyOnHand - TransQty)
Any suggestions?
Also...is there a better, more efficient way to build this feature?