473,660 Members | 2,445 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

DataGrid and textBox - Mark and Focus

Hi,

I have DataGrid table and TextBox in my form. the table contains names and i
use the textBox to enter letters to search specific customer. i want that the
user will be able to navigate the DataGrid with the UP and Down arrows while
the focus is on the TextBox and to mark the selected row.

for example, when the form loads,the focus is on the Textbox and the first
row is marked, the textbox is empty. i enter G and the table contains all the
names that begins with a G, the focus is still on the textbox and the first
name that begins with a G is marked, now, i saw that the name i look for is
at the 3rd row, so i want to navigate with the down arrow to this row, and
each time i press the down arrow i want the row i point at will be marked and
if the user will decide to add to the G also I, the focus will be back to the
textBox which will contain now GI.

how can it be done?

thanks,
Nov 17 '05 #1
0 1290

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

Similar topics

0
4042
by: Faith | last post by:
I found code on www.codeproject.com. Here is a sample it is called DataGridColumnDropDown. I modified it to use the text box when I wanted it to depended on a certain search criteria. Public Class ExtendedSearchFieldValueColumnStyle Inherits DataGridTextBoxColumn Public WithEvents ColumnComboBox As ComboBox Public WithEvents ColumnTextBox As TextBox
0
1882
by: ED M. | last post by:
Hello all...I'm new to the board. I have a problem that I hope someone here might be able to solve for me. I am doing some clientside validation using Javascript. The text I am testing is within a textbox that is part of a datagrid. To complicate things, the datagrid is part of a user control. The following code is all part of the user control. The validation part of the script works fine. However, when I try to set the focus...
0
1194
by: JoRo | last post by:
I am working on a project where I want a very user-friendly interface. I have a datagrid of categories that uses the EditCommandColumn to do in-line editing of the category name. On the page is also a textbox field with an "Add" button to create new categories (This is outside of the datagrid). When the page first loads I use Page.RegisterHiddenField("__EVENTTARGET", "btnAdd");
1
1772
by: Gidi | last post by:
Hi All, i have a datagrid table that contains customers names, and a textbox which the user enters the customer name and the datagrid's dataset is updated so the customer name will be first. anyway i want to that user will be able also to navigate with the down and up arrows throw the names that already displayed. my foucus is always on the textbox (becuase if i put the focus on the datagrid i won't be able to enter any more charachters...
1
3973
by: Gidi | last post by:
Hi, I have DataGrid table and TextBox in my form. the table contains names and i use the textBox to enter letters to search specific customer. i want that the user will be able to navigate the DataGrid with the UP and Down arrows while the focus is on the TextBox and to mark the selected row. for example, when the form loads,the focus is on the Textbox and the first row is marked, the textbox is empty. i enter G and the table contains...
0
1738
by: Luis Esteban Valencia | last post by:
Once a user clicks "add new row", a new row is created in my Datagrid. The datasource is huge so they have to scroll to the bottom of the page to edit the data in the new row. I have come across two EE solutions which use javascript to focus on the textbox in the "editcommandcolumn" mode. However, these solutions were made for non-autogenerated columns. I NEED autogenerated columns for my project. Is it possible to give focus to a...
1
2358
by: jimb | last post by:
I can get the dropdownlist into the datagrid, and I can populate it, but I can't read it. Anybody have a working example of a dropdownlist in an editable grid? Thanks. -- .. http://sf-f.org, weblog and search engine for fans and writers of
5
1125
by: HS1 | last post by:
Hello I have a DataGrid and using some TextBox(es) to present data of this DataGrid. I can show the data by setting fields for these TextBox (in design view). However, I want to write codes (event handler) so that when I change focus of each row in DataGrid, the data value of the row will be presented in TextBox Thank you S. Hoa
13
2472
by: pmcguire | last post by:
I have a DataGrid control for which I have also created several new extended DataGridColumnStyles. They behave pretty nicely, but I can't figure out how to implement Selected Item formatting for them. In a plain vanilla DataGrid, when you click on the RowHeader, the appropriate row changes colors. I ASSUME this should be done in the Paint (or PaintText) override of the DataGridColumnStyle in question. My problem is that I don't know...
0
8341
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
8754
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...
0
8630
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
7362
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...
0
4177
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 last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4343
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2760
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
2
1984
muto222
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.