GeoffS Level: VB Lord

 Registered: 29-09-2004 Posts: 606
|
Re: rum time error 3704
Hi,
The main problem lies within your Connection String.
App.Path returns the path to the directory in which your Project resides, but it does not include a backslash at the end so you need to insert this between the App.Path variable and the name of your database.
The ReadWrite mode should not have a vertical bar between the 2 words - this bar is placed when mixing 2 modes - such as "ReadWrite|Share Deny None"
You also add 2 quotes with nothing in them, so really they are not doing anything.
Amend your Connection String to:-
conConnection.ConnectionString = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & _
App.Path & Chr(92) & "dbtransaction.mdb;Mode=Share Deny None;Persist Security Info=False"
In addition, you will still have problems manipulating the returned Recordset as you have not specified a Lock Type that will allow you to Add New Records, so I suggest you change the rst Open to:-
rstRecordSet.Open "select * from transaction", conConnection, adOpenDynamic, adLockPessimistic
____________________________
multi-tasking - the ability to hang more than one app. at the same time.
|