Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Insert a Table into an Access DataBase

Status
Not open for further replies.

plopez

Technical User
Apr 2, 2002
66
0
0
CL
Hi...I need to know the way to insert a Table into an existent Access DataBase using VB6 Code.

I appreciatte ur help.
 
Do you have an existing table somewhere (another database for example) and you just want to copy it to an Access DB?

OR

Do you want to create a NEW table in an Access database?
 
Code:
sql = "CREATE TABLE YourTableName(FieldName1 Char(40), FieldName2 Char(25), FieldName3 INT, FieldName4 Char(8))"
cn.Execute sql
DoEvents

HTH


The True measure of an individual is how he treats a person who can do him absolutely no good.
 
I am creating a table with VB6 Code and I need to add this table to an existing Access DB.




 
waytech2003 and ChewDoggie have given you two ways to do it. Take your pick.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top