Submit child window and leave parent window open.

3 posts, 0 answers
  1. Lee
    Lee avatar
    3 posts
    Member since:
    Dec 2013

    Posted 04 Jun 2015 Link to this post


     I have an MVC site using Kendo that shows a popup window when a button is clicked.

    This window has a textbox and another button. When the button is clicked another popup window is opened, so we now have 2 popup windows open.

    The 2nd popup contains a grid and 2 hidden textboxes that are populated when an item is selected in the grid.

    What needs to happen is:

    When I submit the popup with the grid, I need to update the model and close it, but leave the parent popup open and populate the textbox with the content of one of the hidden textboxes.

    My problem is:

    I submit the child popup, but I cannot force the parent popup to stay open and update. I get errors if I call the popup directly and if I call the index the model is updated, but the parent popup is also closed.

     If anyone can understand what I have written, please help!?!?



  2. Lee
    Lee avatar
    3 posts
    Member since:
    Dec 2013

    Posted 04 Jun 2015 in reply to Lee Link to this post

    As a note I am using Kendo wrappers.

    The code in the parent window to open the child window is:

    .HtmlAttributes(new { @style = "float: left; width: 250px;" })

    .Content("Select Location")
    .Events(ev => ev.Click("open_Window"))
    .HtmlAttributes(new { @style = "float: left; margin-left: 5px;", action = "GetLocation", controller = "Start", control = "locationSelection" }))
    <div style="display: none" class="popup">
    .Title("Select Location")
    .HtmlAttributes(new { style = "height: 70%;"})

  3. Daniel
    Daniel avatar
    2110 posts

    Posted 08 Jun 2015 Link to this post

    Hello Lee,

    I am not sure if I understand to which action is the grid popup submitted but you should render the index view with the updated model and use the Visible method to leave the parent popup opened when the data is submitted:

    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
Back to Top