Solved

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

Posted on 2011-03-16
2
729 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
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

DevOps Toolchain Recommendations

Read this Gartner Research Note and discover how your IT organization can automate and optimize DevOps processes using a toolchain architecture.

Question has a verified solution.

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

Introduction This article shows how to use the open source plupload control to upload multiple images. The images are resized on the client side before uploading and the upload is done in chunks. Background I had to provide a way for user…
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 is used to tweak the memory usage for your computer, it is used for servers more so than workstations but just be careful editing registry settings as it may cause irreversible results. I hold no responsibility for anything you do to the regist…
Hi friends,  in this video  I'll show you how new windows 10 user can learn the using of windows 10. Thank you.

862 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

25 Experts available now in Live!

Get 1:1 Help Now