Last post Nov 19, 2019 12:12 PM by Khuram.Shahzad
Nov 18, 2019 06:51 AM|erum|LINK
I have view which have button that loads partial view contain (modal popup) .this modal popup have two buttons . yes and no
I write click handler in shared layout file i.e handler for yes and no . i need to send back message to view to show which button click yes or no
what is way out to implement this , Please note down that this alert message i need to use every page (view ) in my application ,so that why i wrote in share file .
Nov 19, 2019 03:00 AM|jiadongm|LINK
Please note down that this alert message i need to use every page (view ) in my application ,so that why i wrote in share file .
I think there is no need to write the click handler in layout view. If you want to use the alert message in every page, I suggest you save the message in controller with session, then you can get the value form session in page.
Nov 19, 2019 03:07 AM|erum|LINK
session may expire !! then
Nov 19, 2019 12:12 PM|Khuram.Shahzad|LINK
if (confirm('Are you sure you want to save this thing into the database?'))
// Save it!
// Do nothing!
like ShowConfirmDialog('api/controller/action','get') => display confirm dialog and on confirmation execute action method by url.
if you design some custom control then you may use: