We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
close icon

Selected value in MultiColumnDropDown

Hello,

How do you determine the selected item and its value in a MultiColumnDropDown from the post method in controller code after the submit button is pressed for example.

Thanks,
Doug

1 Reply

GA Gurunathan A Syncfusion Team July 25, 2013 12:31 PM UTC

Hi Doug,

Thanks for contacting Syncfusion Support.

To retrieve the selected value from the MulticolumnDropdown control in corresponding post action, pass the argument in the name of MultiColumnDropdown control id and in the type of “string” to the corresponding post action. Please refer the following code snippet.

[Code]

[View]

@(Html.Syncfusion().MultiColumnDropDown<Student1>("Multicolumndropdown", "dropdown", columns =>

{

columns.Add(c => c.UniversityCode).HeaderText("Univ Code").Width(100);

columns.Add(c => c.Title).HeaderText("Title").Width(100);

columns.Add(c => c.CourseFees).HeaderText("Course fees").Width(100);

columns.Add(c => c.CGPA).HeaderText("CGPA").Width(100);

}))

[CS]

[AcceptVerbs(HttpVerbs.Post)]

public ActionResult ToolsFeatures(string Multicolumndropdown)

{

string selectedItemText = Multicolumndropdown;

}

For your convenience we have prepared a sample to exhibit this behavior and it is available in the following link.

MultiColumnWithSubmitButton.zip

Kindly let us know, if you have any other queries.

Regards,

Gurunathan A


Loader.
Live Chat Icon For mobile
Up arrow icon