954,541 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Have something to say? Contribute New Article Reply to this Article

combobox = textbox

i have 2 form. form 1 have combobox and second form textbox...how to load data form textbox into combobox..if i type hitachi in text box, automatictly "hitachi" will save in dropdownlist combobox...anyone..please help me...

arezz09
Junior Poster
101 posts since Feb 2011
Reputation Points: 8
Solved Threads: 2
 

See if that works:

Prerequisites:
2 Forms
1 TextBox
1 ComboBox
1 Button

Go to the form where you placed the Button (and the TextBox) and make sure the form's code is the same as below:

Public Class Form2

    Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
        Form1.ComboBox1.Items.Add(TextBox1.Text)
    End Sub
End Class


This should work. If not, reply to this post so I can further help you.

TechSupportGeek
Junior Poster in Training
68 posts since Sep 2009
Reputation Points: 7
Solved Threads: 5
 

it work..but after i relaunch application, item in combobox is not there..

arezz09
Junior Poster
101 posts since Feb 2011
Reputation Points: 8
Solved Threads: 2
 

After closing the forms you will lose all data because all that data was just saved in memory therefore its only temporary. What you want to do is save that data into a database

ninjatalon
Junior Poster in Training
81 posts since Feb 2011
Reputation Points: 11
Solved Threads: 3
 
After closing the forms you will lose all data because all that data was just saved in memory therefore its only temporary. What you want to do is save that data into a database

The other option is to save the information to a CSV file or XML file as to hold the information. Then use a subroutine to load the information on FORM LOAD. This is easy to implement and there are multiple threads in this forum that cover this same information. There is other methods to do this. But a file is easy to deploy and does not need admin privileges to implement. If your issues are resolved please mark the thread as solved.

zinnqu
Junior Poster in Training
86 posts since Jun 2009
Reputation Points: 21
Solved Threads: 15
 

is there any procedure in vb.net for listing the items as dropdownlist in a textbox

ananth3125
Newbie Poster
13 posts since Nov 2011
Reputation Points: 10
Solved Threads: 0
 

This question has already been solved

Post: Markdown Syntax: Formatting Help
You