I set up a combobox with Visual Studio 2003 and it generated the following
code:

//
// serverComboBox
//
this.serverComboBox.DropDownWidth = 121;
this.serverComboBox.Items.AddRange(new object[] {
"AllServers",
"1Server",
"2Server",
"3Server"});
this.serverComboBox.Location = new System.Drawing.Point(136, 16);
this.serverComboBox.Name = "serverComboBox";
this.serverComboBox.Size = new System.Drawing.Size(121, 21);
this.serverComboBox.TabIndex = 0;

The problem is that the items are not displayed in the drop down. If I
select the second item then the combo box text seems to get set to the right
value (in this case "1Server" but I don't see any of the items that I am to
select until it is selected and the combo box text is set to the selection.
How can I enable the viewing of the combo box items?

Thank you.

Kevin

Re: Invisible combobox. by Atul

Atul
Fri Oct 14 05:12:15 CDT 2005

Do you have McAfeee virusscan installed ? It causes problems with symptoms
similar to what you have described.

See http://forums.mcafeehelp.com/viewtopic.php?t=32979


----------------
-Atul, Sky Software http://www.ssware.com
Shell MegaPack For .Net & ActiveX
Windows Explorer GUI Controls
&
Quick-Launch Like Appbars, MSN/Office2003 Style Popups,
System Tray Icons and Shortcuts/Internet Shortcuts
----------------



"Kevin Burton" <KevinBurton@discussions.microsoft.com> wrote in message
news:4BAD8F02-78AC-49E1-9C61-DB1D572934B7@microsoft.com...
>I set up a combobox with Visual Studio 2003 and it generated the following
> code:
>
> //
> // serverComboBox
> //
> this.serverComboBox.DropDownWidth = 121;
> this.serverComboBox.Items.AddRange(new object[] {
> "AllServers",
> "1Server",
> "2Server",
> "3Server"});
> this.serverComboBox.Location = new System.Drawing.Point(136, 16);
> this.serverComboBox.Name = "serverComboBox";
> this.serverComboBox.Size = new System.Drawing.Size(121, 21);
> this.serverComboBox.TabIndex = 0;
>
> The problem is that the items are not displayed in the drop down. If I
> select the second item then the combo box text seems to get set to the
> right
> value (in this case "1Server" but I don't see any of the items that I am
> to
> select until it is selected and the combo box text is set to the
> selection.
> How can I enable the viewing of the combo box items?
>
> Thank you.
>
> Kevin



Re: Invisible combobox. by Ron

Ron
Fri Oct 14 05:17:12 CDT 2005

"Kevin Burton" <KevinBurton@discussions.microsoft.com> wrote in message
news:4BAD8F02-78AC-49E1-9C61-DB1D572934B7@microsoft.com...
>I set up a combobox with Visual Studio 2003 and it generated the following
> code:
>
> //
> // serverComboBox
> //
> this.serverComboBox.DropDownWidth = 121;
> this.serverComboBox.Items.AddRange(new object[] {
> "AllServers",
> "1Server",
> "2Server",
> "3Server"});
> this.serverComboBox.Location = new System.Drawing.Point(136, 16);
> this.serverComboBox.Name = "serverComboBox";
> this.serverComboBox.Size = new System.Drawing.Size(121, 21);
> this.serverComboBox.TabIndex = 0;
>
> The problem is that the items are not displayed in the drop down. If I
> select the second item then the combo box text seems to get set to the
> right
> value (in this case "1Server" but I don't see any of the items that I am
> to
> select until it is selected and the combo box text is set to the
> selection.
> How can I enable the viewing of the combo box items?
>
<snip>
Hi Kevin.
I am not sure why you are setting the TabIndex.
Your code works when I add this line:

this.serverComboBox.SelectedIndex = 0;


HTH
Ron.



Re: Invisible combobox. by KevinBurton

KevinBurton
Fri Oct 14 05:59:02 CDT 2005

I am not setting the tab index. Like I said this code was auto generated by
Visual Studio .NET 2003.

Thank you for the tip. I will try it.

Kevin

"Ron" wrote:

> "Kevin Burton" <KevinBurton@discussions.microsoft.com> wrote in message
> news:4BAD8F02-78AC-49E1-9C61-DB1D572934B7@microsoft.com...
> >I set up a combobox with Visual Studio 2003 and it generated the following
> > code:
> >
> > //
> > // serverComboBox
> > //
> > this.serverComboBox.DropDownWidth = 121;
> > this.serverComboBox.Items.AddRange(new object[] {
> > "AllServers",
> > "1Server",
> > "2Server",
> > "3Server"});
> > this.serverComboBox.Location = new System.Drawing.Point(136, 16);
> > this.serverComboBox.Name = "serverComboBox";
> > this.serverComboBox.Size = new System.Drawing.Size(121, 21);
> > this.serverComboBox.TabIndex = 0;
> >
> > The problem is that the items are not displayed in the drop down. If I
> > select the second item then the combo box text seems to get set to the
> > right
> > value (in this case "1Server" but I don't see any of the items that I am
> > to
> > select until it is selected and the combo box text is set to the
> > selection.
> > How can I enable the viewing of the combo box items?
> >
> <snip>
> Hi Kevin.
> I am not sure why you are setting the TabIndex.
> Your code works when I add this line:
>
> this.serverComboBox.SelectedIndex = 0;
>
>
> HTH
> Ron.
>
>
>

Re: Invisible combobox. by KevinBurton

KevinBurton
Fri Oct 14 06:16:01 CDT 2005

Thank you for your help. For the record this did not solve the problem. I am
hoping that another response indicating that my virus scanner is at fault my
resolve the issue. Thanks again.

Kevin

"Ron" wrote:

> "Kevin Burton" <KevinBurton@discussions.microsoft.com> wrote in message
> news:4BAD8F02-78AC-49E1-9C61-DB1D572934B7@microsoft.com...
> >I set up a combobox with Visual Studio 2003 and it generated the following
> > code:
> >
> > //
> > // serverComboBox
> > //
> > this.serverComboBox.DropDownWidth = 121;
> > this.serverComboBox.Items.AddRange(new object[] {
> > "AllServers",
> > "1Server",
> > "2Server",
> > "3Server"});
> > this.serverComboBox.Location = new System.Drawing.Point(136, 16);
> > this.serverComboBox.Name = "serverComboBox";
> > this.serverComboBox.Size = new System.Drawing.Size(121, 21);
> > this.serverComboBox.TabIndex = 0;
> >
> > The problem is that the items are not displayed in the drop down. If I
> > select the second item then the combo box text seems to get set to the
> > right
> > value (in this case "1Server" but I don't see any of the items that I am
> > to
> > select until it is selected and the combo box text is set to the
> > selection.
> > How can I enable the viewing of the combo box items?
> >
> <snip>
> Hi Kevin.
> I am not sure why you are setting the TabIndex.
> Your code works when I add this line:
>
> this.serverComboBox.SelectedIndex = 0;
>
>
> HTH
> Ron.
>
>
>

Re: Invisible combobox. by Herfried

Herfried
Fri Oct 14 07:04:30 CDT 2005

"Kevin Burton" <KevinBurton@discussions.microsoft.com> schrieb:
>I set up a combobox with Visual Studio 2003 and it generated the following
> code:
>
> //
> // serverComboBox
> //
> this.serverComboBox.DropDownWidth = 121;
> this.serverComboBox.Items.AddRange(new object[] {
> "AllServers",
> "1Server",
> "2Server",
> "3Server"});
> this.serverComboBox.Location = new System.Drawing.Point(136, 16);
> this.serverComboBox.Name = "serverComboBox";
> this.serverComboBox.Size = new System.Drawing.Size(121, 21);
> this.serverComboBox.TabIndex = 0;
>
> The problem is that the items are not displayed in the drop down. If I
> select the second item then the combo box text seems to get set to the
> right
> value (in this case "1Server" but I don't see any of the items that I am
> to
> select until it is selected and the combo box text is set to the
> selection.

Fixing the problem of missing text in controls and messageboxes
<URL:http://dotnet.mvps.org/dotnet/faqs/?id=controlsmissingtextbug&lang=en>

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>