Solved

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

Posted on 2011-09-27
3
230 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
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 12

Expert Comment

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

Author Comment

by:welcome 123
ID: 36712174
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
ID: 36712186
Instead of HyperLinkField try using TemplateField with HyperLink control like here.
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Asp.Net Session Question 2 36
Record locking on classic ASP 3 40
vb.net deleting excel sheet in workbook 11 36
Set arraylist as datatable 2 11
Creating an analog clock UserControl seems fairly straight forward.  It is, after all, essentially just a circle with several lines in it!  Two common approaches for rendering an analog clock typically involve either manually calculating points with…
Parsing a CSV file is a task that we are confronted with regularly, and although there are a vast number of means to do this, as a newbie, the field can be confusing and the tools can seem complex. A simple solution to parsing a customized CSV fi…
Although Jacob Bernoulli (1654-1705) has been credited as the creator of "Binomial Distribution Table", Gottfried Leibniz (1646-1716) did his dissertation on the subject in 1666; Leibniz you may recall is the co-inventor of "Calculus" and beat Isaac…
The Email Laundry PDF encryption service allows companies to send confidential encrypted  emails to anybody. The PDF document can also contain attachments that are embedded in the encrypted PDF. The password is randomly generated by The Email Laundr…

726 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