JerryVT
|
| Posted: 10/08/2004, 1:27 PM |
|
Hi,
I have a Main page with 4 Grids displaying text fields and pictures.
Users click on each grid to insert/edit their content from a separate pop-up window which has a form with Upload component.
I'd like to close this pop-up window after user will click on ADD or Submit buttons and refresh the Main window to show the updated Grid.
Any help would be appreciated!
Thank you
ASP/WIN XP
|
|
|
 |
Anothersledhead
Posts: 44
|
| Posted: 10/08/2004, 7:48 PM |
|
My solution was to add a seperate html button called Refresh and Close. Set the input laungauge to Javascript and set the onclick event to opener.location.reload(); self.close() I have tried to do this on the Add or Submit form buttons but have had trouble with the information not being submitted to the database. Hope this helps.
|
 |
 |
peterr
Posts: 5971
|
| Posted: 10/09/2004, 4:18 AM |
|
I was going to say that similar functionality is implemented right here in this forum and on this page, when you click on "Subscription Options". The only difference seems to be that the page is refreshed only when some options wrere changed in the pop-up window. I don't even know how this works here but you could review the JavaScript on this pop-up page.
_________________
Peter R.
YesSoftware Forums Moderator
For product support please visit http://support.yessoftware.com |
 |
 |
David Harrison
|
| Posted: 10/09/2004, 10:59 AM |
|
I have done this very thing. I have a page called closer and I set the
return page to the Closer page. The Closer page has javascript during the
OnLoad event that closes the window.
David Harrison
"Anothersledhead" <Anothersledhead@forum.codecharge> wrote in message
news:2416751737d132@news.codecharge.com...
> My solution was to add a seperate html button called Refresh and
Close.
> Set the input laungauge to Javascript and set the onclick event to
> opener.location.reload(); self.close() I have tried to do
this on
> the Add or Submit form buttons but have had trouble with the information
not
> being submitted to the database. Hope this helps.
> ---------------------------------------
> Sent from YesSoftware forum
> http://forums.codecharge.com/
>
|
|
|
 |
JerryVT
|
| Posted: 10/16/2004, 4:07 PM |
|
Anothersledhead, Peter & David Harrison,
Thank you all for good help.
I created an empty page and put:
window.opener.location.reload();
window.close();
into page_onload function.
Works perfectly!
jerry
|
|
|
 |
Rudeman
|
| Posted: 11/10/2004, 9:21 AM |
|
Here is an interesting one....Say the user has already entered a load of data into text boxes on the parent page then uses a pop-up to ubdate the contents on a dropdown box located on the parent page. The refresh action of the parent page causes all of the data that was typed into the text boxes to disappear since the refresh took place. any thoughts???
|
|
|
 |
peterr
Posts: 5971
|
| Posted: 11/10/2004, 12:58 PM |
|
I think that you cannot refresh a page if you don't want to loose the data entered by a user. The only 2 options that I remember seeing are:
1. Update controls on the parent page without refreshing it.
2. Submit a form within the parent page via JavaScript, then re-display the page with the form in Edit mode.
_________________
Peter R.
YesSoftware Forums Moderator
For product support please visit http://support.yessoftware.com |
 |
 |
srinivas
Posts: 54
|
| Posted: 11/14/2004, 5:18 PM |
|
If you are going to use the following code:
Quote :
window.opener.location.reload();
window.close();
If the window.opener you are referring to is itself opened by another Window.Open function, then you run into some nasty issues. I had run myself into this wall before, so thought of mentioning that here.
-Srinivas
|
 |
 |