This is a migrated thread and some comments may be shown as answers.

[Solved] DropDownListFor

0 Answers 98 Views
ComboBox
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Joshua
Top achievements
Rank 1
Joshua asked on 14 Oct 2011, 05:01 PM
I have declared my dropdownlistFor like so:

@(Html.Telerik().DropDownListFor(c => c.CommonFieldsModel.SelectedOperatingNumberId)

.Name(

 

"SelectOperatingNumber")

)

I am trying to use some client side code like so:

var ddl= $('#SelectOperatingNumber').data('tDropDownList');

 ddl.dataBind(e);

 ddl.select(0);

BUT my ddl object fails and does not get a value.
Is this because I am using FOR on the end of my declaration?  Most examples don't use the FOR.

Please advise how I get a reference to my dropdown if I use FOR on the end of dropdownlist


Josh


Tags
ComboBox
Asked by
Joshua
Top achievements
Rank 1
Share this question
or