Hi all,
I the below code example how do i need to program it so i dont need to hard code the path to the data source? I have the data source defined in my administrator tools but i dont know how i need to do it so i can point only to cost_accounting.mdb in vba.
Thanks
I the below code example how do i need to program it so i dont need to hard code the path to the data source? I have the data source defined in my administrator tools but i dont know how i need to do it so i can point only to cost_accounting.mdb in vba.
Thanks
Code:
' connect to the Access database
Set cn = New ADODB.Connection
cn.Open "Provider=Microsoft.Jet.OLEDB.4.0; " & _
"Data Source=C:\CAS\cost_accounting.mdb;"