Solved

Close Modal Popup OnClick

Posted on 2008-10-26
3
5,476 Views
Last Modified: 2012-05-05
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
Comment
Question by:grogo21
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 20

Expert Comment

by:Juan_Barrera
ID: 22810339
0
 

Author Comment

by:grogo21
ID: 22813952
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
 
LVL 20

Accepted Solution

by:
Juan_Barrera earned 500 total points
ID: 22818330
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

Instantly Create Instructional Tutorials

Contextual Guidance at the moment of need helps your employees adopt to new software or processes instantly. Boost knowledge retention and employee engagement step-by-step with one easy solution.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article discusses the difference between strict equality operator and equality operator in JavaScript. The Need: Because JavaScript performs an implicit type conversion when performing comparisons, we have to take this into account when wri…
It was really hard time for me to get the understanding of Delegates in C#. I went through many websites and articles but I found them very clumsy. After going through those sites, I noted down the points in a easy way so here I am sharing that unde…
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…
Suggested Courses

623 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question