How to use popup window editing datagrid items?

J

Joseph Yang

Hello all,

I have a datagrid bounded with an Arraylist containing contact
objects, and a edit button (<asp:imagebutton/>) in each row

When I click edit button, I want a window popup so I can edit the
selected contact, so when I click this button, I find out which
contact get selected, put it in session

But the problem is: popup window shows up first before I put the
object into the session

Any ideas or suggestions?

Thanks

Joseph
 
S

S. Justin Gengo

Joseph,

How about creating the popup window by calling it using the body tag as a
server control?

What this means is that your page would post back where you would set the
session variable, then you would attach the javascript for the popup to the
body tag using the onload event. This way the session would be set before
the popup window is created.

I have sample code on how to use the body tag as a server control on my web
site, www.aboutfortunate.com, just search the code library for: "body tag
used as server control" or something similar.

Sincerely,

--
S. Justin Gengo, MCP
Web Developer

Free code library at:
www.aboutfortunate.com

"Out of chaos comes order."
Nietzche
 

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

Forum statistics

Threads
473,755
Messages
2,569,535
Members
45,007
Latest member
obedient dusk

Latest Threads

Top