473,322 Members | 1,538 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,322 software developers and data experts.

ASP DataGrid with C# code-behind question

Whenever I put a DataGrid onto an ASP page that has C# code-behind, the
code-behind method for DataGrid_SelectionChanged() doesn't fire off unless
I've double clicked the DataGrid in design view and had Visual Studio send me
to the code. It's as if it doesn't realize that I've coded the method until
I double click on the DataGrid. In the current project I'm working on, this
poses a problem since I'm not able to see the DataGrid in design view (since
it's inside of an ASP Table that's inside of an ASP Panel...VS doesn't like
to display the Datagrid for some reason here). Any suggestions on what I can
do to get this to work? Thanks!
Nov 16 '05 #1
1 1470
Hi,

Double clicking o a control while in the designer create the handler for
the default event. if you do not do that it's not created,

If you need a handler for another event just select the control in the
designer, go to properties, change to events ( by default it's int eh
properties listing) and double click in the desired event.
if for some reason you cannot use de designer all you have to do is manually
create the handler method with the correct signature and assign it to the
event of the control, usually you do this either in the constructor or in
the InitializeComponent methods
cheers,

--
Ignacio Machin,
ignacio.machin AT dot.state.fl.us
Florida Department Of Transportation
"Tom S" <Tom S@discussions.microsoft.com> wrote in message
news:AF**********************************@microsof t.com...
Whenever I put a DataGrid onto an ASP page that has C# code-behind, the
code-behind method for DataGrid_SelectionChanged() doesn't fire off unless
I've double clicked the DataGrid in design view and had Visual Studio send
me
to the code. It's as if it doesn't realize that I've coded the method
until
I double click on the DataGrid. In the current project I'm working on,
this
poses a problem since I'm not able to see the DataGrid in design view
(since
it's inside of an ASP Table that's inside of an ASP Panel...VS doesn't
like
to display the Datagrid for some reason here). Any suggestions on what I
can
do to get this to work? Thanks!

Nov 16 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

8
by: Ashish Shridharan | last post by:
Hi All I have been trying to add a control to the header cell of a datagrid on my ASP.NET page. These controls are defined in the HTML as ASP.NET web controls. They are being added into the...
3
by: Ryan Liu | last post by:
Hi there, I got a NullReferenceException when delete last row in a datagrid. I had hard time to solve since it does not occur in my own code. I put a datagrid in my inherited user control,...
5
by: tshad | last post by:
Is there a way to carry data that I have already read from the datagrid from page to page? I am looking at my Datagrid that I page through and when the user says get the next page, I have to go...
12
by: Ashish Shridharan | last post by:
Hi All I have been trying to add a control to the header cell of a datagrid on my ASP.NET page. These controls are defined in the HTML as ASP.NET web controls. They are being added into the...
9
by: rn5a | last post by:
A Form has a DataGrid which displays records from a SQL Server 2005 DB table. Users can modify the records using this DataGrid for which I am using EditCommandColumn in the DataGrid. This is the...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.