Send value from child window to parent

J

Joe

I need to popup a window, allow the user to select an image, update the
parent window with this new value (requires a refresh) and then close the
child window.


Are there any examples of something similar to this?

Thanks,
Joe
 
W

Walter Wang [MSFT]

Hi Joe,

Basically, you will need to use JavaScript to open the new window, from the
new window, you can use 'window.opener' to reference the parent window and
make the parent page reload or navigate to another location.

In your case, I understand the popup window will let the user select an
image and the image will be needed to show on the parent with a reloading,
depend on your implementation detail, you could either reload the parent
page with a QueryString parameter (to the new image name) or first save the
new image name in backend (from the client page with a postback of this
page) and reload the parent page.

You can find an example to how to reload the parent page from the popup
window:

#Refresh a GridView control on the parent page, from a pop up window - The
Code Project - ASP.NET
http://www.codeproject.com/aspnet/GridViewRefreshFromParent.asp


Please feel free to reply here to let me know if there's anything unclear.
Thanks.


Sincerely,
Walter Wang ([email protected], remove 'online.')
Microsoft Online Community Support

==================================================
Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/subscriptions/managednewsgroups/default.aspx#notif
ications. If you are using Outlook Express, please make sure you clear the
check box "Tools/Options/Read: Get 300 headers at a time" to see your reply
promptly.

Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 1 business day is acceptable. Please note that each follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach the
most efficient resolution. The offering is not appropriate for situations
that require urgent, real-time or phone-based interactions or complex
project analysis and dump analysis issues. Issues of this nature are best
handled working with a dedicated Microsoft Support Engineer by contacting
Microsoft Customer Support Services (CSS) at
http://msdn.microsoft.com/subscriptions/support/default.aspx.
==================================================

This posting is provided "AS IS" with no warranties, and confers no rights.
 
W

Walter Wang [MSFT]

Hi Joe,

Have you seen my last reply? Please feel free to let me know if there's
anything unclear.


Regards,
Walter Wang ([email protected], remove 'online.')
Microsoft Online Community Support

==================================================
When responding to posts, please "Reply to Group" via your newsreader so
that others may learn and benefit from your issue.
==================================================

This posting is provided "AS IS" with no warranties, and confers no rights.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,581
Members
45,056
Latest member
GlycogenSupporthealth

Latest Threads

Top