473,587 Members | 2,501 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

datagrid top left corner cell - selects All - what event is fired?

Hello,

When clicking on the top left corner of a datagridview - then entire
contents of the datagridview is selected. When clicking on that cell - what
event gets triggered/fired? I tried RowHeaderCell, ColumnHeaderCel l, but
none of these events fired when I click on the top left corner cell of the
datagrid. I was hoping to do something like

console.WriteLi ne(e.ColumnInde x.ToString)

and maybe that would return -1, but I am not able to locate what event fires
when clicking on the Select All cell. Any suggestions appreciated.

Thanks,
Rich
May 8 '07 #1
2 3273
On May 8, 11:35 am, Rich <R...@discussio ns.microsoft.co mwrote:
Hello,

When clicking on the top left corner of a datagridview - then entire
contents of the datagridview is selected. When clicking on that cell - what
event gets triggered/fired? I tried RowHeaderCell, ColumnHeaderCel l, but
none of these events fired when I click on the top left corner cell of the
datagrid. I was hoping to do something like

console.WriteLi ne(e.ColumnInde x.ToString)

and maybe that would return -1, but I am not able to locate what event fires
when clicking on the Select All cell. Any suggestions appreciated.

Thanks,
Rich
AFAIK SelectionChange d is the only event that will fire, but it will
fire more than just when you click the "select all" cell. Perhaps you
could subclass the control and add in your own event that fires only
on that cell.

Thanks,

Seth Rowe

May 8 '07 #2
Thanks.

"rowe_newsgroup s" wrote:
On May 8, 11:35 am, Rich <R...@discussio ns.microsoft.co mwrote:
Hello,

When clicking on the top left corner of a datagridview - then entire
contents of the datagridview is selected. When clicking on that cell - what
event gets triggered/fired? I tried RowHeaderCell, ColumnHeaderCel l, but
none of these events fired when I click on the top left corner cell of the
datagrid. I was hoping to do something like

console.WriteLi ne(e.ColumnInde x.ToString)

and maybe that would return -1, but I am not able to locate what event fires
when clicking on the Select All cell. Any suggestions appreciated.

Thanks,
Rich

AFAIK SelectionChange d is the only event that will fire, but it will
fire more than just when you click the "select all" cell. Perhaps you
could subclass the control and add in your own event that fires only
on that cell.

Thanks,

Seth Rowe

May 11 '07 #3

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

Similar topics

6
2800
by: TJ | last post by:
I've got a calendar that is based on the concept of lots of blocks that are spans with float:left. I would like to be able to have a detail section on the right side of the screen, so that when the user selects an item on the calendar, the detail can get displayed on the right side there. What I have below appears to look perfect in mozilla...
2
9914
by: Chris Plowman | last post by:
Hi all, I was wondering if anyone can help me with a really annoying problem I have been having. I made a derived datagrid class that will select the row when a user clicks anywhere on a cell (multi-select without modifier keys). I got that working fine, but I also wanted to keep rows selected after a sort, which I do by storing the row's...
6
1706
by: BBFrost | last post by:
I'm using Net 1.1 (2003) SP1 & Windows 2000 Here's the issue ... Rows 12 thru 24 are selected in a datagrid. The user now unselects rows 12 thru 24 and selects rows 45 thru 70 ??? How can I tell that the user has reselected a different set of rows in a datagrid.
1
4300
by: Rick | last post by:
Hello all, I hope all is well with you. I am having a seriously difficult time with this problem. Allow me to set up the problem. I have a System.Web.UI.Page with the following controls (watch the layout, some have child controls):
1
1217
by: Chris | last post by:
Hello All, Need some help here. I'm building an asp.net app that uses a datagrid. I have created a template column and added a dropdownlist to it. What I'd like to happen is have the database get updated each time the user selects a different value from the dropdownlist without having to press a submit button or anything. I've been trying...
2
3477
by: Ryan Liu | last post by:
Can someone give a sample to prevent a row from being deleted in a datatable? I tried e.Row.RejectChanges(); in dt_RowDeleting() but seems does not work. I need verify if there other data using data in this row before actually remove it from datagrid. I can certainly control with Delete button. But if I want to allow the user to use...
15
3091
by: glenn | last post by:
Hi folks, I have a DropDownList in a DataGrid that is populated from records in a database. I want to add a value that might be a string such as "Select a Company" for the first item since an OnSelectedIndex event is not fired if you select the first item. Does anyone know of an easy way to do this?
9
2712
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 code: <script runat="server"> Dim sqlConn As New SqlConnection(".....") Sub Page_Load(ByVal obj As Object, ByVal ea As EventArgs) If Not...
0
2152
by: =?Utf-8?B?UmljaA==?= | last post by:
In a datagridview, the first column header cell is columnHeader(0), which is immediately to the right of the Top Left Corner Select All cell. And the first RowHeader cell is RowHeaderCell(0) which is immediately below the Top Left Corner Select All cell. When clicking on the Top Left Corner SelectAll cell, which selects all the...
0
7849
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language...
0
8215
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. ...
0
8347
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that...
1
7973
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For...
0
8220
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the...
1
5718
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 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 a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes...
0
3879
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2358
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
0
1189
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating...

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.