Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 5504
  • Last Modified:

Close Modal Popup OnClick

Hello, I am using a ajax ModalPopupExtender.  I was wondering how i can hide the modal popup if a user clicks outside the panel (in the grayed out area around the panel).  I have a button on the page which will hide the popup when it is clicked.  How can I call the buttons click event when a user clicks outside the popup using java script?

Thanks
0
grogo21
Asked:
grogo21
  • 2
1 Solution
 
grogo21Author Commented:
Hello,
thanks for the link but I need to close the popup when someone clicks outside of it.  How can i determing when a user clicked outside of the popup so that I can close the popup using javascript provided on that link.

Thanks
0
 
Juan_BarreraCommented:
In that case, I think you'd be better off using PopupControl extender, rather than ModalPopup.
It will, automatically, close when the user clicks outside the window.
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now