Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

Cursor stuck in Combobox

Posted on 2004-09-13
7
369 Views
Last Modified: 2012-08-13
I have a combobox on a windows form.  The combobox is not a required field so it can be left blank.  However, when the user focuses on the combobox, it will not release the cursor and allow the user to select any of the other controls on the page until they select an item from the dropdown menu.  Is this by design?  If so, it stinks and I need a way around it.  Any help is gratefully appreciated.

Matt
0
Comment
Question by:mglace390
  • 3
  • 2
7 Comments
 
LVL 5

Expert Comment

by:tzxie2000
ID: 12044829
how about add a blank as an item into the combobox
you can see many similar design in internet
0
 
LVL 2

Author Comment

by:mglace390
ID: 12045080
That is a possible solution however it sounds like a workaround to me.  Is this a bug?  Why is the same thing not happening to the other combo boxes on the form?  Could it have to do with the way it is populated?  The combo I populate using the DataSource property acts as it should and the combo that is causing the error above is populated using the AddRange method.
0
 
LVL 5

Expert Comment

by:tzxie2000
ID: 12045139
do you use databinding?
whether the combobox binding value is not allow null value?
0
Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

 
LVL 2

Author Comment

by:mglace390
ID: 12046853
I do use databinding and I bind the SelectedItem to a string column of a datatable.  The column I'm binding to is nillable therefore I should be able to leave the combobox blank.  Is this what you are referring to?
0
 
LVL 2

Author Comment

by:mglace390
ID: 12047154
I solved the problem by taking out the databinding all together.  I simply set the combo box's SelectedItem property to the value of the field in the DataRow in the constructor and vise versa in the form closing event.  Works exactly how I want it to.  Thank you for your help anyway.

Matt
0
 
LVL 1

Accepted Solution

by:
Computer101 earned 0 total points
ID: 12269833
PAQed, with points refunded (125)

Computer101
E-E Admin
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

This article aims to explain the working of CircularLogArchiver. This tool was designed to solve the buildup of log file in cases where systems do not support circular logging or where circular logging is not enabled
The article shows the basic steps of integrating an HTML theme template into an ASP.NET MVC project
Two types of users will appreciate AOMEI Backupper Pro: 1 - Those with PCIe drives (and haven't found cloning software that works on them). 2 - Those who want a fast clone of their boot drive (no re-boots needed) and it can clone your drive wh…

860 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question