ASP.Net/VB - Need to refresh showmodaldialog from another page - Need jedi

Posted on 2009-12-20
Last Modified: 2012-05-08
Hello all,

I have a aspx page that in my code behind I call showmodaldialog.  This opens a popup form and then the user clicks page down on that dialog which calls another processing page on the form action submit.

After my code runs on the processing page in the page load, I want to close that processing window immediately and refresh the modal aspx page so a page load occurs.  I added <base TARGET="_self"> to the modal dialog header as well.  Any idea?

I have tried the following in my processing page after the code runs the save:

  Dim scriptString As New StringBuilder

            scriptString.append("<script language=JavaScript>")
            scriptString.Append("return false;")

            If (Not IsStartupScriptRegistered("Startup")) Then
                RegisterStartupScript("Startup", scriptString.ToString)
            End If

But still not working.  Thanks for any help
Question by:sbornstein2
    LVL 9

    Accepted Solution

    Below works for me perfectly

    Open in new window

    function PopUpFunction()
        var WinSettings = "center:yes;resizable:no;dialogwidth: 400px;dialogHeight:300px"
        var MyArgs = window.showModalDialog("PopUPpagetoOpen.aspx", '', WinSettings);
    <asp:LinkButton ID="Link_NewCity" runat="server" CssClass="NoteExample" OnClientClick="CreateNewCity()"  >New City</asp:LinkButton>

    Open in new window


    Author Comment

    i posted on the other post it looks like your doing the reload from the same call and page that is not what I am trying to do.  I need to reload the modal from another page.

    Featured Post

    What Should I Do With This Threat Intelligence?

    Are you wondering if you actually need threat intelligence? The answer is yes. We explain the basics for creating useful threat intelligence.

    Join & Write a Comment

    Introduction HTML checkboxes provide the perfect way for a web developer to receive client input when the client's options might be none, one or many.  But the PHP code for processing the checkboxes can be confusing at first.  What if a checkbox is…
    This article discusses the difference between strict equality operator and equality operator in JavaScript. The Need: Because JavaScript performs an implicit type conversion when performing comparisons, we have to take this into account when wri…
    The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
    The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

    733 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    23 Experts available now in Live!

    Get 1:1 Help Now