Log in

View Full Version : Fill Userform From Database


esperanto234
Jan 19, 2010, 10:52 AM
Hi, This is the Ultimate Question!!




I already finished my program in VBA, it has a userform for filling data into Word.

It has a bunch of textboxes.

But people has to fill de information into the textboxes every time they open the userform. Information that is already in a databse in excel.

My question is: How can I do to fill automatically some textboxes in the userform, when it's open, base on a database in excel?

This databse has in every line a unique ID, so it's impossible to repeat the same subject.

For example:

ID NAME ADDRESS PHONE
1234 Phill Smith Street 0987655543
1443 Eddy Lincoln Street 0923455668




TEXTBOXES NAMES:
Id.text
Name.text
Address.text
Phone.text




THANK YOU VEEEEEEERY MUCH

ScottGem
Jan 19, 2010, 11:44 AM
You need to connect to the database. This can be done in a number of different ways. I would search the WEB for examples of connecting a VB app to an external database file.