Quantcast
Channel: ASP.NET Core
Viewing all articles
Browse latest Browse all 9386

Partial page - Load Div - In Ajax

$
0
0

Hi Team,

To Load the partial view in MVC5 i was using Ajax.ActionLink , But in MVC core 2.0, i couldnt load the @Ajax object itself.

error in the screen shot below:

https://ibb.co/kL1U8T

How i can achieve it in Core?

My scenario will be there will be rows in the grid.

In each row there will be a button (Approve), on the click of the Approve button i have to replace the Approve button with  text box (Approval Date) and Submit button.

on click of submit button, i have to replace the full div  which has (Text box and Submit button) with Label  ie. Submitted Successfully.

<div id="Dashboard_1">
@Ajax.ActionLink(
"Approve", "ClassBookingResult", "Educator",
new { ClassID = item.ClassID},
new AjaxOptions
{
InsertionMode = InsertionMode.Replace,
UpdateTargetId = "Dashboard_1"
},
new { @class = "btn btn-success" })</div>


Viewing all articles
Browse latest Browse all 9386

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>