I am using Razor Syntax. In my issue scenarion, I have a select dropdown, And when the user selects empName, a Pop Up opens. In this Popup I call a method with Razor which takes 2 parameters. the 2nd parameter is the empName(value selected in select dropdown).

How to pass this selected value as a 2nd parameter?

<select id="empName">
    <option value="">--Select--</option>
      <option>A</option>
      <option>B</option>
      <option>C</option>
</select

HTML of Pop Up Dialog, Which opens when User selects & clicks Open PopUp Btn.

<div>
    @foreach (var item in new obj.getMasterFields('Category', par2))
    {
         <label for="@item.Key">@item.Value</label> <br />
         ....
    }
</div>

Note : The Popup is Twitter Bootstrap Modal opened with Jquery.

Related posts

Recent Viewed