Calculated field producing possible 4 different results - Programmers Heaven

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories

Welcome to the new platform of Programmer's Heaven! We apologize for the inconvenience caused, if you visited us from a broken link of the previous version. The main reason to move to a new platform is to provide more effective and collaborative experience to you all. Please feel free to experience the new platform and use its exciting features. Contact us for any issue that you need to get clarified. We are more than happy to help you.

Calculated field producing possible 4 different results

thuzinecthuzinec Posts: 1Member
I need help with the syntax in a calculated field. I will give you an example of what I am trying to accomplish.

Yes and Out of State $9,000 result in field $9,000
No and Out of State $6,500 result in field $6,500
No and In State $5000 result in field $5,000
Yes and In State $7,500 result in field $7,500

Result: IIf([y/nField]=-1,[InStateAndYes],[InStateAndNo]) And (IIf([y/nField]=0,[OutStateYes],[OutStateNo]))

The [InStateAndYes] is a field in the table which contains 7500, similarly the other fields contain:
[InStateAndNo]=5000
[OutStateAndYes]=9000
[OutStateAndNo]=6500

Can this be done?
Thanks for your time.

Sign In or Register to comment.