Solved

Add new item to ComboBox in WinForm vb.net and automatic refresh the box.

Posted on 2009-04-02
2
1,050 Views
Last Modified: 2013-11-26
I'm building a WinForm in VIsual Studio 2008 and I've the following question.

On the form I've a ComboBox Customer. But a new customer isn't in my dataset / database so I've to open a new form AddCustomer and when I'm ready and close the form the ComboBox must be refreshed / fill agian. How can I do this easy?

If it's posible I want to used the keydown function to open de new form.

Hope somebody can help me.

Bart Jan
0
Comment
Question by:prinsbj
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 53

Accepted Solution

by:
Dhaest earned 500 total points
ID: 24057240
So if I understand it correctly: You have a mainform which holds a combobox with all your customers.
When one customer is not in there, you open a new form and create a new customer. After adding this to the database, you close this form and return to the mainform ?

Can you show how you call your "new customer" form ? Do you call it with showdialog ?
If so, you can refresh the box after this statement
0
 

Author Closing Comment

by:prinsbj
ID: 31566044
Hello Dhaest,

This was what I needed. I used the .show() function and not .showdialog()

THANK A LOT

Bart Jan
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Whether you've completed a degree in computer sciences or you're a self-taught programmer, writing your first lines of code in the real world is always a challenge. Here are some of the most common pitfalls for new programmers.
Real-time is more about the business, not the technology. In day-to-day life, to make real-time decisions like buying or investing, business needs the latest information(e.g. Gold Rate/Stock Rate). Unlike traditional days, you need not wait for a fe…
An introduction to basic programming syntax in Java by creating a simple program. Viewers can follow the tutorial as they create their first class in Java. Definitions and explanations about each element are given to help prepare viewers for future …
In this fourth video of the Xpdf series, we discuss and demonstrate the PDFinfo utility, which retrieves the contents of a PDF's Info Dictionary, as well as some other information, including the page count. We show how to isolate the page count in a…

738 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question