Send request to server with parameter in mvc razor view

Total Post:1

Points:7
C#
 395  View(s)
Ratings:
Rate this:

Here is my code, i am not able to send request to server with parameter on button click. 

 <td>
    @Html.ActionLink("Edit", "Edit", new { Id = Data.StudentId })
 </td>


  1. Post:44

    Points:310
    Re: Send request to server with parameter in mvc razor view

    Hi Aarush,

    After analyzed your code i have found that you are missing "@" in your parameter.

    Kindly follow given line of code:

     <td>
    
        @Html.ActionLink("Edit", "Edit", new { @Id = Data.StudentId })
     </td>

Answer

NEWSLETTER

Enter your email address here always to be updated. We promise not to spam!