Zimbra offers Open Source email server software and shared calendar for Linux and the Mac
Go Back   Zimbra :: Forums > Zimbra Collaboration Suite > Zimlets

Welcome to the Zimbra :: Forums!
Welcome, if you would like to post a comment please register. We also encourage you to explore all things Zimbra with our team and members of the community.

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 02-03-2007, 05:45 AM
Starter Member
 
Posts: 2
Default DwtSelect and detecting selection

Greetings,

I am working on a zimlet that requires a few different select drop downs. The choice in the first drop down determines the choices in the second drop down. How would one detect a choice being made in a drop down? DwtSelectionEvent?

If this is the case, could you post a quick example as I am having a bit of trouble with this one.

Thanks!

SP
Reply With Quote
  #2 (permalink)  
Old 02-06-2007, 10:27 AM
Zimbra Employee
 
Posts: 14
Default

You can do that by adding a change listener. Use this line of code to add the listener to your select:
Code:
MyClass.prototype.createSelect =
function() {
	var select = new DwtSelect(....);
	select.addChangeListener(new AjxListener(this, this._changeListener));
};
And write a method to handle the change event.
Code:
MyClass.prototype._changeListener =
function(event) {
	// Do something interesting here.
	alert('Changed');
};
Reply With Quote
  #3 (permalink)  
Old 02-07-2007, 06:54 PM
Starter Member
 
Posts: 2
Default

Thanks, I will try that out.

SP
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes


Why Join?

Registering let's you ask questions, makes it easier to search, displays any files attached to posts, and notifies you about replies.

blog.zimbra.com




 

SEO by vBSEO ©2011, Crawlability, Inc.