Loading ...
Sorry, an error occurred while loading the content.

Handle Close Event in YAHOO.widget.Dialog

Expand Messages
  • Ali Bin Jamil
    Hi I am using the YAHOO.widget.Dialog and I want to handle the close event of the Dialog. I want to do some processing and then close the dialog. Thanks. ABJ
    Message 1 of 4 , May 25, 2008
    • 0 Attachment
      Hi

      I am using the YAHOO.widget.Dialog and I want to handle the close event of the Dialog. I want to do some processing and then close the dialog.

      Thanks.

      ABJ

    • alibinjamil
      Any one ? ... event of the Dialog. I want to do some processing and then close the dialog.
      Message 2 of 4 , May 28, 2008
      • 0 Attachment
        Any one ?

        --- In ydn-javascript@yahoogroups.com, Ali Bin Jamil <alibinjamil@...>
        wrote:
        >
        > Hi
        >
        > I am using the YAHOO.widget.Dialog and I want to handle the close
        event of the Dialog. I want to do some processing and then close the
        dialog.
        >
        > Thanks.
        >
        > ABJ
        >
      • bretlevy
        Can you clarify? Do you mean the close of a panel? There is no way to close a form per se. ~~bret ... event of the Dialog. I want to do some processing and
        Message 3 of 4 , May 28, 2008
        • 0 Attachment
          Can you clarify? Do you mean the close of a panel? There is no way
          to close a "form" per se.

          ~~bret


          --- In ydn-javascript@yahoogroups.com, Ali Bin Jamil
          <alibinjamil@...> wrote:
          >
          > Hi
          >
          > I am using the YAHOO.widget.Dialog and I want to handle the close
          event of the Dialog. I want to do some processing and then close the
          dialog.
          >
          > Thanks.
          >
          > ABJ
          >
        • Jacob Davenport
          Sounds like you want to disable the normal event that occurs when you click the close icon and put in your own. Like this, perhaps: var dialog = blahblahblah;
          Message 4 of 4 , Jun 2, 2008
          • 0 Attachment
            Sounds like you want to disable the normal event that occurs when you
            click the close icon and put in your own. Like this, perhaps:

            var dialog = blahblahblah;
            YAHOO.util.Event.removeListener(dialog.close, "click");
            YAHOO.util.Event.addListener(dialog.close, "click", myDialogClose);

            Inside the myDialogClose function, you can do your processing and then
            run:

            dialog.hide;

            or

            dialog.destroy;

            Is that what you're trying to do? I'm doing something similar, where
            a dialog box might open several other panels, and when the main dialog
            box is closed, I want it to destroy all the panels. So my dialog
            close procedure runs through a list of all known subpanels and
            destroys them, including the original dialog box.

            -Jacob

            --- In ydn-javascript@yahoogroups.com, Ali Bin Jamil <alibinjamil@...>
            wrote:
            > I am using the YAHOO.widget.Dialog and I want to handle the close
            event of the Dialog. I want to do some processing and then close the
            dialog.
          Your message has been successfully submitted and would be delivered to recipients shortly.