Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8816243
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T04:34:34+00:00 2026-06-14T04:34:34+00:00

My question is Is there a way to bind data to a comboBox without

  • 0

My question is “Is there a way to bind data to a comboBox without the selectedItem and text values being changed / populated?” (I want the comboBox to stay blank)

This is an EXAMPLE of what I am doing:

        Dictionary<int,string> test = new Dictionary<int,string>();
        test.Add(1, "Company1");
        test.Add(2, "Company2");
        test.Add(3, "Company3");
        test.Add(4, "Company4");
        test.Add(5, "Company5");
        test.Add(6, "Company6");

        var list = test.Select(x => new { CompanyName = x.Value }).ToList();

        comboBox1.DataSource = list;
        comboBox1.DisplayMember = "CompanyName";
        comboBox1.ValueMember = "CompanyName";
        comboBox1.SelectedItem = null;

If you run this code, it works fine, because it loads so fast, it looks like the comboBox stays blank.

However, if you step through the code, you will see that the SelectedItem and Text values get changed when the DataSource is assigned to “list”.

My actual LINQ query is quite a bit bigger, and thus slower to load. My comboBox “flashes” the Text value before it gets cleared out, and I want to remove this ugly flash.

I have tried different combinations of setting SelectedItem and Text values to null (or “”) before and after the DataSource assignment, but I cannot get the “flash” to go away.

Any suggestions are greatly appreciated! =)

EDIT: I also want to add that this only happens on the initial form load… If I change the bindingsource and then reset back to my original (running the exact same code again), it doesn’t “flash”… Not sure if this helps or makes a difference…

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-14T04:34:35+00:00Added an answer on June 14, 2026 at 4:34 am

    Another simple suggestion would be to just add the blank CompanyName as the first item in a list

    list.Insert(0, "");
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Silly question - Is there a way to download the iPhone SDK without Xcode
Question: Is there a way to load a lein plugin, say codex or lein-beanstalk,
Question Is there a way to define a method only once in C# (in
Question: Is there a way to check if a given font is one of
there's a question: Is there any way to pair Bluetooth device in Windows programmatically?
Possible duplicate question: Is there a way to indefinitely pause a thread? In my
The real question: Is there a way to clear certain attributes for all components
I have a very theoretical question: Is there a way to ban the use
Simple question here: is there any way to convert from a jagged array to
My question is: is there a way with a DataContext/Table mapping to implement some

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.