Toggle TextDisplayObject to On with a Checkbox


Not a programmer but trying to muddle my way through…

I set up an Invoice form. Some (but not all) invoices need to have a notice attached. I’ve created a TextDisplayObject with a formula that displays the correct text and I’ve given that TextDisplayObject a name.

I’ve also created a DataButtonObject that I would like to be able to use to toggle the TextDisplayObject on and off. I can’t figure out how to connect these two objects to achieve my intentions but I suspect that there must be some way of doing this.

Attached is a screenshot of my setup.

Thanks in advance for any help.


You need to use a formula in your text display.

?(variable="","","All styles are closeout etc.")

The variable would be the one set by your data button.


If I understand the original question correctly the data button needs to be linked to a database field set up for this purpose, not a variable. That would allow you to designate some records as closeout and some not closeout. (If a variable is used, then either ALL invoices would have this message, or ALL would not have the message.) For example, you might call this field Closeout. Set up the data button so that this field contains an x when checked, and nothing when unchecked. Then your Text Display Object needs to have this formula:

?(Closeout="","","All Sales Are Closeout"+cr()+"All Sales Are Final"+cr()+"No Exchanges or Returns")

You won’t need any programming at all, just this formula. You mentioned that you gave the Text Display object a name, but that is not necessary for this, the formula takes care of everything. As you move up and down to different records in the database you’ll see the notice appear and disappear automatically.



That worked perfectly.

Thanks so much!!!