Contact Login Register
h M

Data Springs Modules Community Questions & Answers

Add onchange event to ComboBox

My combo box's short field name is "Category." And it has a class assigned to it named, "target." I want to add an onchange event to the combo box. (not onblur or onclick or down or up)

I followed the link provided by Ryan in this other forum question: 


to the documentation for the change handler: 

And I have followed the directions but cannot get anything to happen when the combo box is changed. I suspect that my problem is syntax. 

It tells me to add the following jquery. I am adding it to the initial javascript section of the form. (is this the right place to add this?)

$( ".target" ).change(function() {
"Handler for .change() called." );


This should be what watches for when the combo box is changed.

Note, I have added the class named, "target" to the combo box field so as to match the way the sample code is identifying the field to watch.

So finally, my question is, why does this not raise an alert when the combo box is changed?  Should I be using different syntax for the JQuery change function?

I have tried: 

1.   $("#Category").change(function() {

2.    $("#dnn_ctr5663_DynamicForms_Responses_40d7770f-880b-4af5-ad56-6f5157e441a3").change(function() {

3.   $(Category_FieldID).change(function() {

4.   And many more different syntax's.

What is the right way to set up this on change event?

Thank you in advance!




asked 6/21/2016
Mark Buelsing159
Mark Buelsing
  • Oops, the event handler I pasted above was missing the word, "alert". here is the correct code. - still doesn't work for me.

    $( ".target" ).change(function() {
    Handler for .change() called." );
    }); - Mark Buelsing 6/21/2016

  • OK, I pasted it twice and it is still not there. you'll have to take my word for it that the line includes the word alert and the open parentheses. - Mark Buelsing 6/21/2016

0 Answers

Your Answer

In order to provide an answer to this question, you must Login

I am flagging this question because...

10 inform moderator flags remaining

I am deleting this question because...

I am flagging this answer because...

10 inform moderator flags remaining

Flagging a Post

You have already flagged this post. Clicking "Remove Flag" below will remove your flag, thus reducing the count by one as well.

I am deleting this answer because...

Enter your email below AND grab your spot in our big giveaway!

The winner will receive the entire Data Springs Collection 7.0 - Designed to get your website up and running like a DNN superhero (spandex not included).

Luxury replica watches
konulu porno
deneme bonusu maltcasino bahis siteleri
escort beylikduzu sex izle