A button master

I’d like to have a custom button-master to close modal panels on my site. Each button’s interaction would differ, according to the name of the panel to be closed. I made the master, but so far I cannot assign any interaction to it when I place it on a panel. What am I doing wrong? Is a master not appropriate here?

Hi!

A master is appropriate. What you need to do is “raise an event” by going into the master and creating a Click or Tap interaction on the button in the master that raises an event called, say, OnClick:

Then, when you are outside of the master and select the master, you’ll see this OnClick event, in which you can place the script that you want to run when the master is clicked:

JoX (or anybody):

Thanks for the info. Now I’m batting about .400, which is not so bad I guess. Here’s the situation.

  1. I have several pages. Each has several modal panels. Each panel has a button or two (SAVE and/or CANCEL and/or SUBMIT and/or NEXT etc.).

  2. The raised events tutorial page says: “Select a widget in the master whose event you want to raise”. My master has only one thing in it: a button. So I select the button, I guess.

  3. After successfully doing the raised event thing with one button, I duplicated it to make the next ones. That didn’t work out so well. If a duplication strategy is OK, do I have to do “raised event” again for each button? Or does “RE” come along with the duplication. The actions needed for these buttons are different: sometimes closing the panel, sometimes doing nothing (for now), and sometimes closing the panel and opening the next panel in the sequence (the NEXT button). I have not been successful here. Can I use the NEXT button on several panels on the same page triggering different events (sometimes closing the panel and opening the next; other times just closing the (last) panel)?

  4. The tutorial page says that one can configure each version of the raised event “at the page-level”. I have several versions of the same button on different panels on the SAME page. Is that a problem?

  5. Naming is a bit of an issue. I’m not sure whether a name is required (of a version of the RE), and I’m not sure if names must be unique.

Other than the above, things are working out pretty well. Any help you can offer is appreciated.