Home AMX User Forum AMX Design Tools

detect a "hide pop-up" event

Hi again!

I would like to know if there is a way to detect a "hide or close pop-up" event; because i would like to set a certain button state every time a concrete pop-up is close (and it could be closed through many buttons).

Many thanks to all and salutes!

Comments

  • jjamesjjames Posts: 2,908
    Tie the "close" button to an event and track it with a variable.

    I don't use page feedback in my code, but this could be a way to go as well.
  • CT-DallasCT-Dallas Posts: 157
    Another thing you can consider is the little used string output port available to you in TPDesign. Find the ways to close or hide the pop-up and have the button press send you a string on the port YOU specify. Track the strings (your own syntax protocal here) through a data event for the port you specify and flag away.
  • DHawthorneDHawthorne Posts: 4,584
    When the panel does online, send it a TPAGEON command in the online event. This will make sure page tracking is on. Then monitor the STRING event for the panel. When a popup comes on, it will generate a string that will say 'PPN-'<page name>, and when it goes off it will be PPF instead of PPN. All string events are on the panel's port 1.
  • MorgoZMorgoZ Posts: 116
    Thanks to all!

    I were looking for something like DHawthorne said, because i considered catching the "close" events through all the buttons that closes the pop-up, but the problem is that they are many, and i think that it is "cleaner" catching the event just through the pop-up than through all the buttons.

    But like i said, many thanks to all!!!!!!

    Salutes!
  • jjamesjjames Posts: 2,908
    DHawthorne wrote: »
    When the panel does online, send it a TPAGEON command in the online event. This will make sure page tracking is on. Then monitor the STRING event for the panel. When a popup comes on, it will generate a string that will say 'PPN-'<page name>, and when it goes off it will be PPF instead of PPN. All string events are on the panel's port 1.

    That was the other alternative I was alluding to - just didn't know the TPAGEON command would initiate it. That would probably be the *easiest* way. Learn something new everyday!
Sign In or Register to comment.