Skip to content
Loading
 The above code is working fine, why do you need Action and controller when you could paas null.Paste the above code in MVC view and please test.
+5
  • Farhan Ahmed
    +3
    @Html.ActionLink("Delete", "DeleteCategory", "Admin", new { item.CategoryID }, new {data_toggle = "modal", data_target = "#Delete", id="deleteActionLink", data_parameter="" })
    +3
  • Khushbu Saini
    +3
    https://www.c-sharpcorner.com/blogs/model-popup-in-asp-net-core-31 Hi please visit this link this the solution of your problem ...of model popup over link button click
    +3
  • Jignesh Kumar
    +3
    Hi Alex,
     
    Please use this link,
    https://www.c-sharpcorner.com/UploadFile/092589/implementing-modal-pop-up-in-mvc-application/ 
    https://forums.asp.net/t/2145886.aspx?How+to+open+the+jquery+dialog+from+the+Html+ActionLink+of+webgrid+ 
    +3
  • +3
    Thank you all for you time and your help, Mr Ahmed I like you idea but this code doesn't work may be you omit something, I am posting it 
    @Html.ActionLink("Delete", "DeleteCategory", "Admin", new { item.CategoryID }, new {data_toggle = "modal", data_target = "#Delete", id="deleteActionLink", data_parameter="" })
     
    Thank you 
    +3
  • +3
    One more thing with the html.actionlink is I have to provide an action and a controller, I dunno how to make it work without providing an action and a controller.
    +3
  • +3
    No Idea on how to have the html.actionlink to go to my jquery function.
    this is not working
    @html.actionlink("link text","#", null, new{onclick="myfunction"})... whatever I have tried from the internet would ether go to the page controller and action method or would not trigger the jquery function.
    +3
  • Mageshwaran R
    +3
    Hi ,
    please refer this link:
    https://www.c-sharpcorner.com/UploadFile/092589/implementing-modal-pop-up-in-mvc-application/
    +3