0

My front end developer used jQuery multiselect for filters for a search results page. The data in the multiselect is populated dynamically from the database.

To populate the checkboxlist inside the multiselect I have done something like

<div id="multiselect">
   <asp:CheckboxList runat="server" id="chk"></asp:Checkboxlist>
</div>

The checkboxlist is dynamically populated from the database. A button click event is supposed to read values of the checkboxlist and then filter search results based on that. This displays fine and also the multiselect works fine. But after I've made selections and hit the 'Filter' button, the selections from the asp checkboxlist are not being read by an extension method for the checkboxlist in the code behind.

The immediate issue that jumped out was to check for !Page.IsPostBack which I had already done. But even after fixing that I cannot get the code behind to read any selected values.

Any suggestions as to what might be going on? I might just scratch this approach and go with something else but would like to see if there is anything that can be done regarding this.

1 Answer 1

1

I'm not sure what's going on but I implemented another solution. I have used a hidden field to record any changes on the jquery multiselect and then reading that field's value in the code behind and all is well.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.