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

[Solved] ComboBox not dropping down.

2 Answers 105 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.
Brady
Top achievements
Rank 1
Brady asked on 16 Dec 2010, 11:55 AM
I have the following Razor markup for a dropdown in my view, but when the view renders, the dropdown arrow on the ComboBox is not operational, i.e. although I know there are 2 items in the dropdown, it doesn't drop down when I click the arrow.  I know there are 2 items because I can successfully set SelectedIndex to 0 or 1.

        <div class="editor-field">
            @(Html.Telerik().ComboBox()
                .Name("Provinces")
                .SelectedIndex(1)
                .BindTo(new SelectList(Model.ProvinceList, "ProvinceId""Name"))
                .ClientEvents(events => events.OnChange("provinceChanged"))
            )
        </div>

2 Answers, 1 is accepted

Sort by
0
al
Top achievements
Rank 1
answered on 20 Dec 2010, 12:20 AM
Could be because the javascript function "provinceChanged" "events.OnChange("provinceChanged")"
does not exist or an error inside the function. So javascript error would prevent it from opening. Cheers.

0
Brady
Top achievements
Rank 1
answered on 20 Dec 2010, 09:35 AM
Thanks, it was indeed an error in the JavaScript function.
Tags
ComboBox
Asked by
Brady
Top achievements
Rank 1
Answers by
al
Top achievements
Rank 1
Brady
Top achievements
Rank 1
Share this question
or