473,386 Members | 1,810 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,386 software developers and data experts.

Databound combobox problem (mouse vs. keyboard)

I'm having a really weird problem with a combo box (drop down list) on
a databound form.

I load 3 values programmatically into the combo box "MALE" "FEMALE"
and "UNKNOWN". When I run the app, if I tab to the combo box and type
'm' on the keyboard "MALE" shows up in the combo box, but it doesn't
save when I execute my .update statement. But, if I click on the list
and select "MALE" from the drop down list, it saves into the database
just fine.

The only thing I can think of is that the Selected_Index_Changed event
fires for either the keyboard or the mouse, but the Text_Changed event
only fires with the mouse... I don't even know if that makes a
difference.

What I'd like is for the user to be able to type "m" and have the
value save.... how can I do that??

Using vb 2005 and SQL Server 2005

Thank you,

John
Mar 20 '08 #1
5 2241
On Mar 20, 3:06*pm, JohnRou <john...@ci.green-bay.wi.uswrote:
I'm having a really weird problem with a combo box (drop down list) on
a databound form.

I load 3 values programmatically into the combo box "MALE" "FEMALE"
and "UNKNOWN". *When I run the app, if I tab to the combo box and type
'm' on the keyboard "MALE" shows up in the combo box, but it doesn't
save when I execute my .update statement. *But, if I click on the list
and select "MALE" from the drop down list, it saves into the database
just fine.

The only thing I can think of is that the Selected_Index_Changed event
fires for either the keyboard or the mouse, but the Text_Changed event
only fires with the mouse... I don't even know if that makes a
difference.

What I'd like is for the user to be able to type "m" and have the
value save.... how can I do that??

Using vb 2005 and SQL Server 2005

Thank you,

John
Are you talking about Web application or Windows application ?
Mar 20 '08 #2
>
Are you talking about Web application or Windows application ?- Hide quoted text -
Sorry, Windows app.
Mar 20 '08 #3
On Mar 20, 3:39*pm, JohnRou <john...@ci.green-bay.wi.uswrote:
Are you talking about Web application or Windows application ?- Hide quoted text -

Sorry, Windows app.
please give me code hows you doing ?
Mar 20 '08 #4
>
make one another simple form and do just again . May be you have
missed somhing in you settings ..- Hide quoted text -
I had tried that earlier with the same result. I even created a new
SQL database with just two fields to test it... same result. On my
real form, I have a bunch of comboboxes and they all function the same
way. It's not intermittant and only bothers the combo boxes....
Mar 20 '08 #5
With a lot of help, the problem has been identified. It turns out
that the VB IDE binds comboboxes to the Text property. That is
causing the erratic behavior. If you change the bind to the
SelectedItem value it works fine......
Mar 22 '08 #6

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

Similar topics

4
by: Sue Bricker | last post by:
Greetings. In Access, is there a way to open up a drop-down combobox with keys on the keyboard, instead of using the mouse to click on the down arrow of the combobox? I really prefer to use the...
0
by: George Hartas | last post by:
I am using Visual C# .NET 2003 to make a ComboBox accept both mouse and keyboard selection. For mouse selection code, I double-clicked ComboBox to get the default "comboBox1_SelectedIndexChanged"...
2
by: Horst JENS | last post by:
Hi group, have problems with combobox-control in a form (access 2003). I added VBA-Code to on-Change event of the control. If the user choose an value from the control, the filter of the form...
0
by: Andrus | last post by:
SWF ComboBox dropdown menu first item selection must open picklist. For this I use the following code: protected override void OnSelectedIndexChanged(System.EventArgs e) { if (SelectedIndex != 0...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
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
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,...

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.