Solved

How to avoid page load event calling towce when called froma hyperlink

Posted on 2011-09-27
3
220 Views
Last Modified: 2013-11-05
I have a page which calls another page through a hyperlink in a grid and the page load event is called twice because of this. How to avoid this, the page.ispostback does not work as its being called from another page and the hyperlink in the grid is something like this below:

<asp:HyperLinkField HeaderText="RNo" Text="CBRNo" DataTextField="RNo" DataNavigateUrlFields="ID" DataNavigateUrlFormatString="Agency.aspx?ID={0}" SortExpression="RNo"/>
0
Comment
Question by:welcome 123
3 Comments
 
LVL 12

Expert Comment

by:Ramkisan Jagtap
Comment Utility
u can use html anchor tag.
<a href="yourpath"></a>
0
 

Author Comment

by:welcome 123
Comment Utility
I have other needs to wher I have to use a grid in which clicking on itemid should take you to another page
0
 
LVL 41

Accepted Solution

by:
guru_sami earned 125 total points
Comment Utility
Instead of HyperLinkField try using TemplateField with HyperLink control like here.
0

Featured Post

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

IntroductionWhile developing web applications, a single page might contain many regions and each region might contain many number of controls with the capability to perform  postback. Many times you might need to perform some action on an ASP.NET po…
The ECB site provides FX rates for major currencies since its inception in 1999 in the form of an XML feed. The files have the following format (reducted for brevity) (CODE) There are three files available HERE (http://www.ecb.europa.eu/stats/exch…
This video discusses moving either the default database or any database to a new volume.
When you create an app prototype with Adobe XD, you can insert system screens -- sharing or Control Center, for example -- with just a few clicks. This video shows you how. You can take the full course on Experts Exchange at http://bit.ly/XDcourse.

743 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now