Populating textbox controls

I

itzzme

I have 3 textboxes on a form. One is based on the values present on the other
two.
For e.g. lets say we have 3 textboxes namely txt1, txt2, txt3.
The conditions to be satisfied are as follows:
if (txt1 = A & txt2 = A) then txt3 = X;
if (txt1 = A & txt2 = B) then txt3 = Y;
if (txt1 = A & txt2 = C) then txt3 = Z;
if (txt1 = B & txt2 = A) then txt3 = P;

and so on..There are 10 conditions in all.
Please can someone suggest an effective way to populate values in txt3
textbox.
Note that the values of txt1 and txt2 are dynamic and are dependent on other
values in the form. So every time the value of any of theese txt1 or txt2
changes, txt3 needs to be updated.

Thanks
 
C

Clay Fox

You would put a rule on txt1 and on txt2 for each of your 10 cases. Actually
what would be easier is to create another boolean field and put your rules on
it when it was true.
Then have just one rule on TXt1 and Txt2 which would set the new field to
true when each was updated. That way you only have one set of rules.
Then create a rule for each you have listed witht he conditions and then a
set field value for Txt3.
Also do not forget to reset your boolean field to false each time at the end
of your rules list.

--
Thanks

Clay Fox

Qdabra Software
http://www.qdabra.com

InfoPathDev.Com
The Largest InfoPath Forum in the World
http://www.infopathdev.com
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top