Hi,
I have an mvc application.
Parent page index.cshtml
Child page create.cshtml
On parent page i have a grid with one column as input button where i use show modal dialog.
I have a requirement when closing the browser button of this show modal dialog parent page should not refresh.
Only parent page should refresh when i click submit button of child window.
Please give me some idea how can i do this.
Index.cshtml inside grid i have this button.
Using window.location.reload it is refreshing parent page also when i click on child window browser button.
Please help!!
Loading

Jitendra ShekhawatPosted Mar 22, 2017, 2:34 AM
Anjali KhanPosted Mar 22, 2017, 1:32 AM
hi
this is my action
public ActionResult Comment(int id)
{
FileViewModel cm = new FileViewModel();
cm.user_ID = id;
return View(cm);
}
Iftikar HussainPosted Jul 17, 2013, 7:55 AM
return JavaScript("window.close();window.opener.document.location.reload();");
Regards,
Iftikar
Deepika ChaudharyPosted Jul 17, 2013, 7:23 AM
Iftikar HussainPosted Jul 17, 2013, 6:36 AM
//your code
Regards,
Iftikar
Deepika ChaudharyPosted Jul 17, 2013, 6:14 AM
Iftikar HussainPosted Jul 17, 2013, 4:44 AM
Try like this
in your index.cshtml
" />
create one javascript method (you can pass all parameter)
in your create.cshtml
Regards,
Iftikar