Click here to Skip to main content
15,889,595 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
in my application i m using gridview . in gridview i dsplay page_name like Home,Contact_us,Master_Page etc. I used Linkbutton to redirect to another page. if i am click on Home Page Linkbutton it goes to Home.aspx page,or if i am click on Contact_us Linkbutton it goest to contact.aspx etc. how can i do this .

Thanks and Regards
Manohar
Posted
Comments
RDBurmon 13-Jun-12 9:31am    
Thanks Everyone who replied to this thread , So Manohar, I think you have got enough responses and you should be able to mark it as your answer and close the thread. Please do so.

use PostBackUrl attribute of link button
 
Share this answer
 
Comments
Manohar Khillare 12-Jun-12 3:52am    
i know i used postbackurl but it going only one page
 
Share this answer
 
Hi,

Try this
C#
((LinkButton)e.Row.FindControl("LinkButton1")).Attributes.Add("onclick", "javascript:window.location = '<%= ResolveUrl(~/test.aspx) %> '" );
 
Share this answer
 
v2

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900