answersLogoWhite

0


Best Answer

The integer for the first string in the collection is zero. The code is shown below:

Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load

ComboBox1.SelectedItem = ComboBox1.Items.Item(0)

End Sub

User Avatar

Wiki User

14y ago
This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: I need to set the SelectedItem of a ComboBox to the first string in the collection. I use VB.NET. What code do I need?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Related questions

By val v by Ref in vbnet?

The Differences of ByVal and ByRef in VB.NET are that ByVal values can not be changed outside the sub, but ByRef values can be.Example:Sub A(ByVal NotChangableValue As String)'YOUR CODEEnd SubSub B(ByRef ChangableValue As String)'YOUR CODEEnd Sub


Is java better than vbnet?

Java is not better than VBNet, nor is VBNet better than Java. Eachone has its advantages and disadvantaged over the other one.


What is the difference between C and Vbnet?

It is just a different coding language, but C is more for business that VBNET


What is datareader in VBNET?

x


What is instance in vbnet?

An instance in VBNet is the same as an instance in any other language; it is the realisation of a type. In object-oriented languages, like VBNet, we say that an object is an instance of a class, where the class defines the object's type.


What is an instance in vbnet?

An instance in VBNet is the same as an instance in any other language; it is the realisation of a type. In object-oriented languages, like VBNet, we say that an object is an instance of a class, where the class defines the object's type.


IS VBNet purely objet oriented?

no


Who is the father of vbnet?

Alan Cooper


What is VBnet's Toolbox?

A part of Visual Basic which displays many items that you can insert into your Form. Items like buttons, textboxes and menustrips. In toolbox we have all items which we use to create a project. It is the collection of items


Who is the developer of vbnet?

Microsoft Microsoft.com/VisualStudio


Is the Class type in VBNET a value type?

NO.


How do you write a VBnet program to find the prime numbers between 100 to 200?

VBnet program to find the prime numbers between 100 to 200?