473,659 Members | 2,886 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Disable Navigation In Datagrid by Arrow Keys

3 New Member
Hi All,
I am using datagrid control in my window application. I am designing the grid by a table and table style to add extra controls in the cells like button and drop down.
Now, I have everything ok, But it want to disable the navigation in the datagrid cells by arrow keys. I dont want to change the cell by the arrows key as the Tab key does.
Is there anybody to help me out.
Thnx in advance.
Mos
Aug 2 '07 #1
1 2868
ezzsakr
1 New Member
Expand|Select|Wrap|Line Numbers
  1. procedure TForm1.DBGrid1KeyDown(Sender: TObject; var Key: Word;
  2.   Shift: TShiftState);
  3. begin
  4. Key:=0;
  5.  
  6. end;
Jan 16 '13 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

4
15453
by: Terry | last post by:
Hey, Having somewhat of an issue, I have a datagrid which is giving me issues. The Datagrid is setup for the user to double click the row, the row is selected and data within that row populates a form for editing. the problem is when a user clicks on a cell instead of the whole row, I get an error. My question is this, is there anyway I can setup the datagrid so when the user clicks on any cell, the whole row is selected not just that...
2
1867
by: PAUL GROSSMAN | last post by:
Hello everyone. I am working with a DataGrid using VB .Net (Windows Forms). I want to make one of the columns un-editable. I was able to do that by setting the .dsName.Tables("TblName").Columns("ColName").ReadOnly = True That made it so you can't change the value in the column, but you're still tabbing into the column (despite the fact you can't change it).
3
9218
by: bardo | last post by:
I have a Datagrid that is inside a panel. I want to use the keyDown event to reconize the arrow keys. But I have no luck at all. The problem is that the keydown event won't fire at all, unless I click on a row (withs will turn blue then) and then click on it again . Now if I press any key the event will fire (except for the arrow keys). I also tried to override the IsInputKey => no luck. I also tried to override the ProcessCmdKey => With...
0
1648
by: ROG | last post by:
Hi all with help from postings on the web, i have a dateTimePicker in one of my columns in the datagrid. However, when i move in to this column using the arrow keys, it automatically pops up, and then any future arrow key presses start changing the date. I don't want this to happen - i'd like the arrow keys to continue navigating around the grid. For the dateTimePicker to become "active", i'd like the user to, say, have to press...
0
1359
by: Bob Morvay | last post by:
My users want to be able to use the Web Datagrid like an excel spreadsheet. This means a fully editible grid with arrow key navigation between cells. The grid seems to support horizontal tabbing between cells but nothing for the arrow keys. I have googled for sample code but the best that I could find was some half completed javascript that captures the key events but doesn't quite show me how to use it in the grid. I was wondering if...
1
2923
by: Geroge D. Lake | last post by:
Hi, I need to disable the resizing of a datagrid. I have tried al day and no luck. Any Ideas? Thanks. George.
6
3302
by: Bruce D | last post by:
I have a datagrid (uggg) that I use and create the columns programmatically...see below. objCol = New DataGridTextBoxColumn objCol.MappingName = "amount" objCol.HeaderText = "Amount" objCol.Width = 60 objCol.Format = "C" objDGTS.GridColumnStyles.Add(objCol) ' create keypress, validating events for this textbox column only Dim dgtb As DataGridTextBox = CType(objCol.TextBox, DataGridTextBox)
0
1927
by: Matt | last post by:
I derived my own custom class from the datagrid class. I overrode the ProcessCmdKey Function, like this, to catch the up and down arrow keys: ====== Protected Overrides Function ProcessCmdKey(ByRef msg As Message, ByVal keyData As Keys) As Boolean Const WM_KEYDOWN As Integer = &H100
3
2559
by: GhanaShyam | last post by:
Hi All, I am working on the winform datagrid. Now I have to disable the cursor movement in the datagrid using teh Arrow keys on keyboard and also I want to disable the mouse wheel (the scroll button) for the datagrid. Please help me in this regard. Its urgent. I will be waiting for the reply... Thanks in Advance, GS
0
8427
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, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8332
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 synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8851
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. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
8746
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 captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
8525
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 most users, this new feature is actually very convenient. If you want to control the update process,...
0
8627
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 choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
7356
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, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6179
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 instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
4335
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?

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.