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

  • Home
  • SEARCH
  • 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 7888321
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 3, 20262026-06-03T05:48:09+00:00 2026-06-03T05:48:09+00:00

Why does a Vaadin ComboBox get invisible when doing setReadOnly(true)? Screenshots normal invisible The

  • 0

Why does a Vaadin ComboBox get invisible when doing setReadOnly(true)?

Screenshots

normal
normal ComboBox - visible

invisible ComboBox with setReadOnly(true) - invisible

The source code

import java.util.List;   
import com.vaadin.ui.ComboBox;

public class PropertyComboBox extends ComboBox
{
    public PropertyComboBox(List<String> properties)
    {
        super();
        for(String property: properties) {this.addItem(property);}
        this.setImmediate(true);
        this.setMultiSelect(false);

        this.setNewItemsAllowed(false);
        this.setInputPrompt("Property");
        this.setReadOnly(true);
    }
}
  • 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-03T05:48:11+00:00Added an answer on June 3, 2026 at 5:48 am

    If you are trying to create a combo box in which the user can’t write anything, check out the NativeSelect component.

    From the API doc:

    This is a simple drop-down select without, for instance, support for multiselect, new items, lazyloading, and other advanced features. Sometimes “native” select without all the bells-and-whistles of the ComboBox is a better choice.

    If you don’t need these features, then you should definetely consider using NativeSelect.

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

Sidebar

Related Questions

Does anyone know how to make this code stop the knob from rotating past
does someone know how I can get Sublime Text 2 to auto-hide the tabs
Does anyone know how Java is able to circumvent the windows MAX_PATH limitations. Using
Does anyone know the name of the context menu that you get when right
Does anyone know of a simple implementation of a checked combobox in WinForms? I
Does any one know about how to create hide and collapse content using vaadin
I'm new to vaadin, and I managed somehow to get an app up and
Does the Java language have delegate features, similar to how C# has support for
Does anyone know how to get IntelliSense to work reliably when working in C/C++
Does someone know of a comparison between ZK and Vaadin ? I'm especially interested

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.