Solved

Attach onclick event to TabContainer/TabPanel

Posted on 2011-09-13
2
1,229 Views
Last Modified: 2012-05-12
I have a simple AJAX TabContainer control on a page with 4 tab panels. When the user clicks the last tab I need a message box to flash up. This event needs to be enabled/disabled on the basis of a value in a database and so code behind control is required (I write in VB). Adding an OnClientClick event to the tabpanel stops the entire control from rendering, whether I do it on the page or in code-behind. What am I missing?
0
Comment
Question by:deveson
[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 Comments
 
LVL 40

Accepted Solution

by:
gurvinder372 earned 125 total points
ID: 36528390
In jquery itself, you can check the variable and bind/unbind the onclick event

if(  flag == true )
{
   $("#last_tab").unbind("click");
}
else
{
   $("#last_tab").bind("click");
}

0
 

Author Closing Comment

by:deveson
ID: 36976778
I am unfamiliar with jquery but guess will need to learn this now to achieve objective
0

Featured Post

Get 15 Days FREE Full-Featured Trial

Benefit from a mission critical IT monitoring with Monitis Premium or get it FREE for your entry level monitoring needs.
-Over 200,000 users
-More than 300,000 websites monitored
-Used in 197 countries
-Recommended by 98% of users

Question has a verified solution.

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

Introduction HyperText Transfer Protocol (http://www.ietf.org/rfc/rfc2616.txt) or "HTTP" is the underpinning of internet communication.  As a teacher of web development I have heard many questions, mostly from my younger students who have come to t…
JavaScript can be used in a browser to change parts of a webpage dynamically. It begins with the following pattern: If condition W is true, do thing X to target Y after event Z. Below are some tips and tricks to help you get started with JavaScript …
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

624 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