name a database

fraser5002
01-08-2004, 02:31 AM
hi i am using a data control at the moment to access the code and to name my databsse i currently to name the database use the datacontrol menu and select the filename and then record source use the table i made my access database in but is there a way to write this in coding i tried
data1.database = ( filename)
data1.recordsource = ( table name)

but it didnt work could any one tell me what to write ( i still want to keep the datacontrol on the screen but i just want the coding of how to name the database and recordsource) thanks

Shurik12
01-08-2004, 07:42 AM
Data1.DatabaseName="c:\Mydb.mdb"
Data1.RecordSource="NameOfTheTable"

EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum