0

I have a results list from a search in MVC which shows rows of data, with an action link.

@Html.ImageLink(Url.Content("~/Content/Images/view.png"), "New Window", "PoPupDetails", "QuickSearch", new { id = item.WardshipCaseID }, new { target = "_self" }, null)

This link calls a public ActionResult PoPupDetails(int id).

with return View("PopupDetails", model);

and a popup opens but it replaces the current form/page.

My question is how do i open a popup using my actino link keeping the same window. I want to close the popup and still see the list of results from my search.

Vitor M. Barbosa
  • 3,286
  • 1
  • 24
  • 36
user2729229
  • 1
  • 1
  • 1
  • You need to return a `PartialView` in some sort of modal/popup window. Have a look here http://stackoverflow.com/questions/16011151/mvc-4-edit-modal-form-using-bootstrap/16011752#16011752 – MattSull Aug 29 '13 at 22:54

1 Answers1

0

Try this,

<input type="button" id="btnpopu" value="Open Modeless popup" onclick="ShowPopup();" />
<script type="text/javascript">
ShowPopup = function () {
    window.open('URL', "PopupWindow", 'width=400px,height=400px,top=150,left=250');
}
</script>  
Jatin patil
  • 4,252
  • 1
  • 18
  • 27