473,473 Members | 2,320 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

DataGridView: Skip ReadOnly cells

I have a DataGridView with some read-only cells.
I want it skips these cells when the user press Tab or Shift+Tab keys.
How can I do this?

Thanks.

Junior.

Oct 4 '06 #1
1 6011
Junior,

You will have to handle the tabbing for the grid, most likely overriding
the ProcessTabKey method on the grid. You will have to determine which
direction to proceed (what if the ALT key is pressed as well, you need to
tab backwards).

I would look at reflector to look at the ProcessTabKey method, and also
the TabToNextCell and TabToPreviousCell methods for guidance on how to find
the next cell. It's not a simple task, but it does look doable.

Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"osmarjunior" <os*********@gmail.comwrote in message
news:11*********************@e3g2000cwe.googlegrou ps.com...
>I have a DataGridView with some read-only cells.
I want it skips these cells when the user press Tab or Shift+Tab keys.
How can I do this?

Thanks.

Junior.

Oct 4 '06 #2

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

Similar topics

8
by: George | last post by:
Hi, I have been trying to see if I can do the following: 1. Create a DataGridView 2. Create 2 columns in the DataGridView (1 textbox and the other combobox) 3. Create a DataTable containing...
0
by: osmarjunior | last post by:
I'm trying to implement this, but without success. What I want is when the user press Tab key in my DataGridView, automatically jump to the next cell, but if the next cell is read only, then jump...
0
by: TonyJ | last post by:
Hello! I have earlier used a grid called flygrid where everything had to be done by coding. I use VS2005 so I have this DataGridView which I can't really understand how to use. I mean what...
1
by: =?Utf-8?B?Q2hyaXN0aWFuIEhhdmVs?= | last post by:
Hi, I have an DataGridView control with the following columns (added using the designer): column1 - DataGridViewTextBoxColumn column2 - DataGridViewComboBoxColumn (values "test1", "test2")...
12
by: cj | last post by:
When viewing a datatable in a datagridview one of the columns in it is a "note" field which can be quite long. I would like to have the note field of the currently selected row of the datagrid...
2
by: Rosco | last post by:
Hello, Quick Overview: I am creating a Windows application using C# and have run across a problem. I’m trying to use a DataGridView in “Bound” mode, but filter the view. I have a database...
3
by: Christian | last post by:
Hi, i create aprogram that load a table from Access DB. i want color rows with different color but when i run the program and i load the datagridview the first time, the rows are white! only when...
1
by: mzahid | last post by:
Hellow All I am new in ASP.Net Application. I have a page with some TextBoxes and GridView. I have Done the Values of Textboxes save into Invoice Table and i want to save Invoice Detail values...
6
by: Ciaran | last post by:
I'm having a really strange issue with the DataGridView control in a VS2008 / .NET 3.5 winforms project. I have a simple form with a grid. In the form constructor I call a function to bind the grind...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
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...
0
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...
1
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...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
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 ...
1
muto222
php
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.