Wrox Programmer Forums
Go Back   Wrox Programmer Forums > .NET > Other .NET > General .NET
|
General .NET For general discussion of MICROSOFT .NET topics that don't fall within any of the other .NET forum subcategories or .NET language forums.  If your question is specific to a language (C# or Visual Basic) or type of application (Windows Forms or ASP.Net) try an applicable forum category. ** PLEASE BE SPECIFIC WITH YOUR QUESTION ** When posting here, provide details regarding the Microsoft .NET language you are using and/or what type of application (Windows/Web Forms, etc) you are working in, if applicable to the question. This will help others answer the question without having to ask.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the General .NET section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old August 26th, 2004, 02:57 AM
Registered User
 
Join Date: Aug 2004
Posts: 6
Thanks: 0
Thanked 0 Times in 0 Posts
Default server control event in modal dialog

i have a pop up window that has a server button.
Now the server button has to insert certain values into database.
and display a msg saying that it inserted.

The problem that i am facing is that, onclick of the save button another window opens up
andd the message is popped on that window.

To close the window that is opened (onclick of the server button)
i have the window .close()

the child window of the popup window closes but the popup itself doesn't close.

can anyone help
this is the code used

 Private Sub btnsave_ServerClick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnsave.ServerClick

    insert into database.


        Response.Write("<script language=Javascript>")
     'Response.Write("window.parent.returnValue='" & ptamt & "';")
        Response.Write("window.parent.close();")
        Response.Write("window.close();" & Chr(13))

        Response.Write("</Script>")



    End Sub

I can always have an option that all the child windows are closed after the code in the button click is executed.
But return one value to the parent window.

kindly help.








Similar Threads
Thread Thread Starter Forum Replies Last Post
Displaying modal dialog from server code gp_mk HTML Code Clinic 16 July 1st, 2007 07:55 AM
how to return value from modal dialog ajaypsingh Javascript 2 May 16th, 2006 05:14 AM
Modal Dialog window Problem anandham Javascript 7 February 16th, 2005 06:08 PM
Modal dialog window eldanh ASP.NET 1.0 and 1.1 Basics 0 August 10th, 2004 02:07 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.