By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
429,616 Members | 2,026 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 429,616 IT Pros & Developers. It's quick & easy.

Moving items from one form to another.

P: 1
Alright soo, I'm working on this program for my programming class using VB 2005 and it's driving me insane.

See the program is like this. The main form has a list box for selected products and beside it is the total for all the products you selected. The other form is list box of all the products you can select it. You can choose what product you want from the products list box, press the add button, and it should send the product and the price over to the list box in the main form, thus comes my trouble.

I cannot get the item from the list box on the second form to add to the listbox on the main form. So how can one add an item from a listbox on one form to another list box on another form?

Help would be greatly appreciated.
Apr 30 '07 #1
Share this Question
Share on Google+
1 Reply


Expert 5K+
P: 8,434
The same way you would add to one on the same form, except that you need to prefix the control name with the form name. In other words, to refer to a text box on Form1 for example, you might say Form1.Text1.Text.
May 1 '07 #2

Post your reply

Sign in to post your reply or Sign up for a free account.