Wrox Programmer Forums
Go Back   Wrox Programmer Forums > ASP.NET and ASP > ASP.NET 1.0 and 1.1 > ASP.NET 1.1
|
ASP.NET 1.1 As of 10/6/2005, this forum is locked as part of the reorganization described here: http://p2p.wrox.com/topic.asp?TOPIC_ID=35394. No posts have been deleted. Open ongoing discussions from the last week have been moved to either ASP.NET 1.0 and 1.1 Beginners http://p2p.wrox.com/asp-net-1-0-1-1-basics-60/ or ASP.NET 1.0 and 1.1 Professional. http://p2p.wrox.com/forum.asp?FORUM_ID=50. See my sticky post inside for more.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the ASP.NET 1.1 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 March 15th, 2005, 06:21 AM
Registered User
 
Join Date: Mar 2005
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default Opening Popup on Click of LinkButton in DataGrid

i have create datagrid ,In datagrid contain template column.
In template column i add Linkbutton and linkbutton text Databound "CadidateId"
('<%#DataBinder.Eval(Container.DataItem,"CadidateI d")%>').
when i click at linkbutton popupwindow show.popupwindow contain in all information of candiate.

i m doing like this:
At Parent Page:
protected void btnlink(object sender Event.Args e)
{
    LinkButton lk=(LinkButton)sender;
    Session["lkbtn"]=lk.Text;
    string s="<script>window.open('popup.aspx','null','height =200,width=100')</script>";
    this.RegisterClientScriptBlock("showpopup",s);
}

At Child Page:
string Id=Session["lkbtn"].ToString();
So get Id of Candidate and show all information at popup.aspx.

But Problem is Happen when i close popup.aspx at click on close button

and refresh parent page. popup.aspx Page Again open .
i want that when refresh parent Page PopWindow Page should be open.
How is Possible in C#,.Net
Please Help Me.
I m Highly Thanking You

sanjay
 
Old March 16th, 2005, 01:46 AM
Friend of Wrox
 
Join Date: Oct 2003
Posts: 326
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via ICQ to Santhi Send a message via MSN to Santhi
Default

Add the javascript code to the onClick event of the LinkButton.
Use Lk.Attributes.Add("onClick",..).This way when you refresh the parent window,pop up wont open up.







Similar Threads
Thread Thread Starter Forum Replies Last Post
Popup window automatically minimized on click! elisabeth Javascript How-To 19 January 29th, 2017 02:43 AM
Why is addhandler for linkbutton.click not working rsearing ASP.NET 2.0 Basics 7 November 12th, 2007 06:06 PM
dynamic linkbutton disappear when click it logoin2 ASP.NET 1.0 and 1.1 Basics 0 December 2nd, 2004 02:39 PM
showing a popup window on click widad Classic ASP Basics 4 October 15th, 2004 09:50 AM





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