0

Hi, it's a very simple question, but I cant see how to solve it!

I'm doing a web form,
I have a button inside a table, the thing is, I can't access to the code of this button,

Usually you just double click on the design view over a button, and you get to the .cs to the part of

 protected void Button1_Click(object sender, EventArgs e)
        {
        }

But I can't double click this button, it selects the entire table.
I have tried writing the code directly, but it doesn't work..

2
Contributors
1
Reply
11
Views
3 Years
Discussion Span
Last Post by JorgeM
1

You can do this in Source View...

On the button control add an attribute called "onclick" so for example,

 <asp:button runat="server" ID="Button1" onclick="Button1_Click">
This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.