greensleeves149
Member
- Local time
- Today, 17:16
- Joined
- Feb 27, 2022
- Messages
- 49
Hello all,
I've been working on an IIF statement on one of the controls on my form and for over 4 days I can't seem to figure it out- so I thought it's time to reach out for some fresh minds and ideas.
Happy to provide more information if required, but I didn't want to bored people with TMI!
Basically I have an IIF statement that uses other fields on the form to return a certain result. When it wasn't working as expected, I've broken down the IIF statement to try and find out where it's falling over and from what I can see, it's not working correctly if I add an 'And' to the IIF statement.
I've tested taking the AND statement out of the formula and if I use either one or the other components, the formula works as expected (so the naming conventions I assume are all correct). As soon as I add the AND back though, the result on the form will always show the 'false' component ("More") when at times it should show the 'true' ("Less")- depending on the other fields on the form off course. There are no error messages showing up either.
Here's the IIF with the And statement:
=IIf(([MinimumRatePurchaseLimit]<>0) And ([TotalOrderAmt]<[MinimumRatePurchaseLimit]),"Less","More")
Could someone please shed some light on this?
Thanking you.
I've been working on an IIF statement on one of the controls on my form and for over 4 days I can't seem to figure it out- so I thought it's time to reach out for some fresh minds and ideas.
Happy to provide more information if required, but I didn't want to bored people with TMI!
Basically I have an IIF statement that uses other fields on the form to return a certain result. When it wasn't working as expected, I've broken down the IIF statement to try and find out where it's falling over and from what I can see, it's not working correctly if I add an 'And' to the IIF statement.
I've tested taking the AND statement out of the formula and if I use either one or the other components, the formula works as expected (so the naming conventions I assume are all correct). As soon as I add the AND back though, the result on the form will always show the 'false' component ("More") when at times it should show the 'true' ("Less")- depending on the other fields on the form off course. There are no error messages showing up either.
Here's the IIF with the And statement:
=IIf(([MinimumRatePurchaseLimit]<>0) And ([TotalOrderAmt]<[MinimumRatePurchaseLimit]),"Less","More")
Could someone please shed some light on this?
Thanking you.