473,805 Members | 1,981 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Child window and repost problem.

Hi,
I've been trying to figure this one out for a while and I'm stalled.

Here's my scenario:

- a Parent window with a datagrid on it. The datagrid has pagination enabled
and has an "Edit" link for each record.

- Once someone clicks on the "Edit" link, a child window pops-up. The user
edits the data and submits the form. All the server code is executed and
then I need to refresh the contents of the parent window and close the child
window. The following 2 lines of code do that:

Response.Write( "<script>opener .document.locat ion.reload();</script>");

Response.Write( "<script>window .close();</script>");

BUT by using this method, IE 6.0 pops-up a warning message saying "the page
cannot be refreshed unless data is submited to the server, click RETRY to
continue". Basically warning you that information is going to be posted to
the server.

Is there any way to get the Client Window to refresh the Parent Window
WITHOUT this warning message popping-up?

(The reason for the "post" being triggered is due to the pagination being
enabled on the data grid, requesting the next page posts the data back to
the server).

THANKS!

Fernando

PS: Same thing happens on Firefox.
Nov 19 '05 #1
4 1326
I'd suggest doing a GET and passing a query string that informs your page
how to do sorting and paging.

-Brock
DevelopMentor
http://staff.develop.com/ballen
Hi,
I've been trying to figure this one out for a while and I'm stalled.
Here's my scenario:

- a Parent window with a datagrid on it. The datagrid has pagination
enabled and has an "Edit" link for each record.

- Once someone clicks on the "Edit" link, a child window pops-up. The
user edits the data and submits the form. All the server code is
executed and then I need to refresh the contents of the parent window
and close the child window. The following 2 lines of code do that:

Response.Write( "<script>opener .document.locat ion.reload();</script>");

Response.Write( "<script>window .close();</script>");

BUT by using this method, IE 6.0 pops-up a warning message saying "the
page cannot be refreshed unless data is submited to the server, click
RETRY to continue". Basically warning you that information is going to
be posted to the server.

Is there any way to get the Client Window to refresh the Parent Window
WITHOUT this warning message popping-up?

(The reason for the "post" being triggered is due to the pagination
being enabled on the data grid, requesting the next page posts the
data back to the server).

THANKS!

Fernando

PS: Same thing happens on Firefox.


Nov 19 '05 #2
Is there a way of doing that in .NET?
I thought everything was based on POSTBACKS.

"Brock Allen" <ba****@NOSPAMd evelop.com> wrote in message
news:55******** **************@ msnews.microsof t.com...
I'd suggest doing a GET and passing a query string that informs your page
how to do sorting and paging.

-Brock
DevelopMentor
http://staff.develop.com/ballen
Hi,
I've been trying to figure this one out for a while and I'm stalled.
Here's my scenario:

- a Parent window with a datagrid on it. The datagrid has pagination
enabled and has an "Edit" link for each record.

- Once someone clicks on the "Edit" link, a child window pops-up. The
user edits the data and submits the form. All the server code is
executed and then I need to refresh the contents of the parent window
and close the child window. The following 2 lines of code do that:

Response.Write( "<script>opener .document.locat ion.reload();</script>");

Response.Write( "<script>window .close();</script>");

BUT by using this method, IE 6.0 pops-up a warning message saying "the
page cannot be refreshed unless data is submited to the server, click
RETRY to continue". Basically warning you that information is going to
be posted to the server.

Is there any way to get the Client Window to refresh the Parent Window
WITHOUT this warning message popping-up?

(The reason for the "post" being triggered is due to the pagination
being enabled on the data grid, requesting the next page posts the
data back to the server).

THANKS!

Fernando

PS: Same thing happens on Firefox.


Nov 19 '05 #3
Sure, you can do this, but you'll have to write code in Page_Load to check
for the QueryString parameters and then use them to sort/page your DataGrid.
Not too much different than doing it in the server event for DataGrid OnSort
or OnPageIndexChan ged.

-Brock
DevelopMentor
http://staff.develop.com/ballen
Is there a way of doing that in .NET?
I thought everything was based on POSTBACKS.
"Brock Allen" <ba****@NOSPAMd evelop.com> wrote in message
news:55******** **************@ msnews.microsof t.com...
I'd suggest doing a GET and passing a query string that informs your
page how to do sorting and paging.

-Brock
DevelopMentor
http://staff.develop.com/ballen
Hi,
I've been trying to figure this one out for a while and I'm stalled.
Here's my scenario:
- a Parent window with a datagrid on it. The datagrid has pagination
enabled and has an "Edit" link for each record.

- Once someone clicks on the "Edit" link, a child window pops-up.
The user edits the data and submits the form. All the server code is
executed and then I need to refresh the contents of the parent
window and close the child window. The following 2 lines of code do
that:

Response.Write( "<script>opener .document.locat ion.reload();</script>"
);

Response.Write( "<script>window .close();</script>");

BUT by using this method, IE 6.0 pops-up a warning message saying
"the page cannot be refreshed unless data is submited to the server,
click RETRY to continue". Basically warning you that information is
going to be posted to the server.

Is there any way to get the Client Window to refresh the Parent
Window WITHOUT this warning message popping-up?

(The reason for the "post" being triggered is due to the pagination
being enabled on the data grid, requesting the next page posts the
data back to the server).

THANKS!

Fernando

PS: Same thing happens on Firefox.


Nov 19 '05 #4
OK,
I get that.
So there's no way to "convert" the datagrid control to use GET instead of
POST?

I ask because my datagrid has pagination and sorting enabled and it would a
lot easier the control would use GET every time a sort order or page index
changed.
(instead of having to implement it all manually)

Just want to make sure before I start coding away.

"Brock Allen" <ba****@NOSPAMd evelop.com> wrote in message
news:55******** **************@ msnews.microsof t.com...
Sure, you can do this, but you'll have to write code in Page_Load to check
for the QueryString parameters and then use them to sort/page your
DataGrid. Not too much different than doing it in the server event for
DataGrid OnSort or OnPageIndexChan ged.

-Brock
DevelopMentor
http://staff.develop.com/ballen
Is there a way of doing that in .NET?
I thought everything was based on POSTBACKS.
"Brock Allen" <ba****@NOSPAMd evelop.com> wrote in message
news:55******** **************@ msnews.microsof t.com...
I'd suggest doing a GET and passing a query string that informs your
page how to do sorting and paging.

-Brock
DevelopMentor
http://staff.develop.com/ballen
Hi,
I've been trying to figure this one out for a while and I'm stalled.
Here's my scenario:
- a Parent window with a datagrid on it. The datagrid has pagination
enabled and has an "Edit" link for each record.

- Once someone clicks on the "Edit" link, a child window pops-up.
The user edits the data and submits the form. All the server code is
executed and then I need to refresh the contents of the parent
window and close the child window. The following 2 lines of code do
that:

Response.Write( "<script>opener .document.locat ion.reload();</script>"
);

Response.Write( "<script>window .close();</script>");

BUT by using this method, IE 6.0 pops-up a warning message saying
"the page cannot be refreshed unless data is submited to the server,
click RETRY to continue". Basically warning you that information is
going to be posted to the server.

Is there any way to get the Client Window to refresh the Parent
Window WITHOUT this warning message popping-up?

(The reason for the "post" being triggered is due to the pagination
being enabled on the data grid, requesting the next page posts the
data back to the server).

THANKS!

Fernando

PS: Same thing happens on Firefox.


Nov 19 '05 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
1777
by: H2 | last post by:
Hi all, Any one know how to open a new windows in a child window using javascript? What I need to do is that, in my main page, there is a button, onclick, it opens one child windows. In the child windows there is a few links. Once the link in the child windows is clicked, I want it to open an other window( like the grandchild window) How do i do it? I can open the child window with no problem, however, when I click on the link in child...
3
5619
by: James Spibey | last post by:
Hi, I have an MDI application which has aboout 10 child windows. The way the app needs to work is that only one window should be visible at a time and it should be maximized within the parent window. I have set all my child windows to be WindowState.Maximized but after showing 2 or 3 windows, the windows all drop back to Normal state. I have tried various things to overcome this inclusing overriding OnResize etc but none seem to give...
4
2036
by: Bonj | last post by:
Further to my last post, I have managed to get a child window to display. But its messages are routed to the same WNDPROC that the main window's messages are routed to - what is the way of identifying from the lParam or wParam whether the message came from a child window or the parent? And what if the message uses some other data in the wParam or lParam? Is it better to use one wndproc for the parent window, and one wndproc for all child windows...
2
23516
by: Raj | last post by:
Hi All, I have a problem with trying to refresh the parent window from child window in order to update data in the parent window. The sequence of events are 1) I click a button in the parent window to open a child window thru javascript window.open 2) I have some functionality in the child window that changes the data
1
1963
by: Bill Borg | last post by:
Hello all, Simple chat app, where the site owner has a master window with all requests for chat, status of each room, etc., and child windows for each separate chat in which the owner is engaged. When the owner closes one of his child windows, I want to update the master window. I understand "reasonably" well how to go about this. The master window launches the children, and maintains an associative array to keep track of each one....
4
10983
by: Steve Barnett | last post by:
I've created a simple MDI application and have designated the Window menu to keep track of the mdi children. When I first load an mdi child, it's caption consists of "File: no file loaded" and this is what appears on the Window menu. Now, after the mdi child loads, I call a method to load a specifically named file. At this point, the child changes it's caption to reflect the new file name. Unfortunately, the Window menu does not update...
4
3565
by: Richard Lewis Haggard | last post by:
What is the mechanism by which a child window can notify its parent that it has been clicked on? -- Richard Lewis Haggard www.Haggard-And-Associates.com
0
9716
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
10360
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10366
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
10105
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
9185
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7646
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6876
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5677
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
3845
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.