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 7543543
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 30, 20262026-05-30T08:27:21+00:00 2026-05-30T08:27:21+00:00

I have a Windows Forms project in Visual Studio 2010 and I was wondering

  • 0

I have a Windows Forms project in Visual Studio 2010 and I was wondering how I would set a default selected value of a dropdown menu.

For example, when I run the project currently the dropdown menu is blank until I click on it and select a value. I want to modify the dropdown menu so that it has a value by default that the user can then change. How can I accomplish this both in the designer view and at runtime through C#?

  • 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-05-30T08:27:23+00:00Added an answer on May 30, 2026 at 8:27 am

    Set property SelectedIndex.

    Run-time:

    comboBox1.SelectedIndex = 0; //Selects the first option
    

    If you want to select option that contains specific text.

    int index = comboBox1.FindString("burger"); //get index
    comboBox1.SelectedIndex = index;
    

    Design-time:

    Select the control, go to property window and look for SelectedIndex property, set the desired index.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have created a simple windows forms visual studio 2010 project in windows 7
When building a Windows Forms project in Visual Studio 2010 I have a following
I have a Windows Forms project in Visual Studio that reads configuration files from
I have a Windows Forms project in Visual Studio 2008, which references a library
I have a Visual Studio 2010 Windows Forms application in which I start a
I have a created a visual studio 2010 project that creates a windows form
I have a Windows project in Visual Studio 2010 in which I store all
I have created a Windows Forms Application project by Visual Studio.Net 2008. In order
When you open a new C# Windows Forms Application project in Visual Studio 2008,
I would like to use log4j.net in my windows forms project. However I have

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.