Solved

Click event for  <asp:DynamicHyperLink runat="server" Action="Edit" Text="Edit"  />

Posted on 2011-03-16
2
738 Views
Last Modified: 2012-05-11
I need to update a Session variale with the time at the moment of clicking on this  asp:DynamicHyperLink

 <asp:DynamicHyperLink runat="server" Action="Edit" Text="Edit"  />

How do I do that?

newbieweb
0
Comment
Question by:newbieweb
[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
2 Comments
 
LVL 8

Accepted Solution

by:
Anurag Agarwal earned 500 total points
ID: 35150068
newbieweb use link button instead of hyperlink to change session value on the click as link button provides you with onclick event that can be executed on server side which u require to change the session values

in aspx page
<asp:LinkButton id="LinkButton1" Text="Click Me" OnClick="LinkButton_Click" runat="server"/>

in .cs page (for finding this just double click the link button )
 
void LinkButton_Click(Object sender, EventArgs e)
      {
        Session["Login"] = "ADMIN";
// some thing like this ..................
      }

0
 

Author Closing Comment

by:newbieweb
ID: 35152003
Thanks.
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone 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

Exception Handling is in the core of any application that is able to dignify its name. In this article, I'll guide you through the process of writing a DRY (Don't Repeat Yourself) Exception Handling mechanism, using Aspect Oriented Programming.
This article aims to explain the working of CircularLogArchiver. This tool was designed to solve the buildup of log file in cases where systems do not support circular logging or where circular logging is not enabled
Come and listen to Percona CEO Peter Zaitsev discuss what’s new in Percona open source software, including Percona Server for MySQL (https://www.percona.com/software/mysql-database/percona-server) and MongoDB (https://www.percona.com/software/mongo-…
This is a high-level webinar that covers the history of enterprise open source database use. It addresses both the advantages companies see in using open source database technologies, as well as the fears and reservations they might have. In this…

688 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