Solved

combobox selection

Posted on 2004-09-16
6
275 Views
Last Modified: 2008-03-06
im assuming this is a really easy question, but when my form loads, i have multiple comboboxs' that appear to be selected. (The text within them that is).....and i cant figure out how to unselect them

thanks!
0
Comment
Question by:bramsquad
  • 3
  • 2
6 Comments
 
LVL 10

Expert Comment

by:Clif
ID: 12075846
Combobox1.SelectedIndex = -1
0
 
LVL 8

Author Comment

by:bramsquad
ID: 12075911
let me rephrase,

i want the item selected, just not the text...

~b
0
 
LVL 19

Accepted Solution

by:
Desp earned 50 total points
ID: 12075939
Combobox1.SelectionStart = 0
0
What Security Threats Are You Missing?

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

 
LVL 8

Author Comment

by:bramsquad
ID: 12106201
Desp:

sortof, but ill give you some since you put me on the right track

heres what you want

Combobox1.SelectionStart = Combobox1.Text.Length

~b
0
 
LVL 19

Expert Comment

by:Desp
ID: 12109273
>>>i want the item selected, just not the text...

what does that mean then?

btw thanks for the C grade, Most of the peoples here dont like to answer the questions of ppls who have Cs and Bs in their question history
0
 
LVL 8

Author Comment

by:bramsquad
ID: 12118361
i use "c" grades sparingly, take a look at my profile.

anyways, the first answer gave no selection in the combo box.  (it was blank, no item at all)

your answer gave me the item i wanted, but the text within the combobox was selected (which is what i was asking how not to do)

the reason your code doesnt work, is it selects the text as position zero.  mine selects the text at the last position, or so to speak, leaves it unselected.  

you didnt provide me with a thourough answer, thats why i gave you a "c"

~b

0

Featured Post

Threat Intelligence Starter Resources

Integrating threat intelligence can be challenging, and not all companies are ready. These resources can help you build awareness and prepare for defense.

Join & Write a Comment

This article explains how to create and use a custom WaterMark textbox class.  The custom WaterMark textbox class allows you to set the WaterMark Background Color and WaterMark text at design time.   IMAGE OF WATERMARKS STEPS Create VB …
The ECB site provides FX rates for major currencies since its inception in 1999 in the form of an XML feed. The files have the following format (reducted for brevity) (CODE) There are three files available HERE (http://www.ecb.europa.eu/stats/exch…
Internet Business Fax to Email Made Easy - With eFax Corporate (http://www.enterprise.efax.com), you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, fr…
This tutorial demonstrates a quick way of adding group price to multiple Magento products.

747 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

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now