Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

GridView Footer Button Custom Eventhandler?

Posted on 2011-03-01
3
Medium Priority
?
491 Views
Last Modified: 2012-05-11
I know about using the GridView RowCommand eventhandler to catch button commandName. Just wondering if there is a way to make a custom eventhander much like using Windows Forms where double-clicking a new button in designer creates a new eventhandler (ie... button1_click).
0
Comment
Question by:pointeman
[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 18

Accepted Solution

by:
ChetOS82 earned 500 total points
ID: 35008634
There is no automatic way (like double-clicking), but you can put an OnClick event like this:

<asp:Button runat="server" ID="button1" OnClick="button1_Click" Text="button" />

in the code-behind:

protected void button1_Click(System.Object sender, System.EventArgs e) {

}
0
 
LVL 29

Assisted Solution

by:Paul Jackson
Paul Jackson earned 500 total points
ID: 35008688
What do you want to do create an event handler for button click ?
Is your button a server control i.e. <asp:Button ...
Go to your code-behind page, at the top of the screen you have 2 dropdownl;istboxes. In the left hand one select the control you want to create an event for, in the right hand one select the event type you want to handle.

If the event handler exists it will take you to it.
If it doesn't it will create the outline of the event handler.

Hope this is what you were after.
0
 

Author Closing Comment

by:pointeman
ID: 35011946
very nice, thanks....
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

ASP.Net to Oracle Connectivity Recently I had to develop an ASP.NET application connecting to an Oracle database.As I am doing it first time ,I had to solve several problems. This article will help to such developers  to develop an ASP.NET client…
International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
Video by: ITPro.TV
In this episode Don builds upon the troubleshooting techniques by demonstrating how to properly monitor a vSphere deployment to detect problems before they occur. He begins the show using tools found within the vSphere suite as ends the show demonst…
In this video, Percona Solution Engineer Dimitri Vanoverbeke discusses why you want to use at least three nodes in a database cluster. To discuss how Percona Consulting can help with your design and architecture needs for your database and infras…
Suggested Courses

636 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