javascript - Disabling a checkbox in a html table cell in row on checking other check box other cell in the same row -


i want disable check box in html table cell when other check box checked in same row in mvc.

the controller code given below:

<table id='mytable1'> <th>buy</th>  <th>sell</th>  <tbody>  @foreach (var item in model)   { <td> <input id="assignchkbx" name="chk" type="checkbox" value="@item.itemid"> </td>   <td> <input id="buy" name="buypo" type="checkbox"  value="@item.itemid"/> </td>`  }  </tbody>   </table> 

i want disable sell when select, buy , vice versa.. pls help... tia..

consider using radio buttons instead. if give them same name (but different ids) automatically check , uncheck each other.


Comments

Popular posts from this blog

user interface - How to replace the Python logo in a Tkinter-based Python GUI app? -

objective c - Greedy NSProgressIndicator Allocation -

how to set an OCR language in Google Drive -