# Re: Connect String incorrect(there is also the same error.

Posted by wen on September 22, 1998 at 08:45:26:

In Reply to: Connect String incorrect posted by 小吴 on September 22, 1998 at 08:23:40:

: 你的 Connect String 格式是错的，你忘了指定数据库位置。
: 把 scnct 改为下行再试一次看看。
: scnct = "DBQ=c:\winnt\db1.mdb;Driver=C:\WINNT\System32\odbcjt32.dll;DriverID=25;FIL=MS Access;UID=;PWD=;"
program as follows:
Public en As rdoEnvironment
Public cn As rdoConnection
Private Sub Form_Load()
Dim scnct As String
Dim rs As rdoResultset
Dim ssql As String

Set en = rdoEngine.rdoEnvironments(0)
scnct = "dbq=c:\winnt\order.mdb;Driver=C:\WINNT\System32\odbcjt32.dll;" _
& "DriverID=25;FIL=MS Access;UID=;PWD=;"
Set cn = en.OpenConnection(dsname:="yuan", prompt:=rdDriverNoPrompt, ReadOnly:=False, Connect:=scnct)
ssql = "select * from branch"
Set rs = cn.OpenResultset(ssql, rdOpenKeyset, rdConcurRowVer)
rs.Edit
rs![branch_id] = "2"
rs.Update
While Not cn.EOF
rs.MoveNext
Wend
rs.Close
cn.Close
End Sub

扂眒忒雄婓NT sever4.0奻腔讽秶醱衔odbc笢扢离剩system dsn:yuan,select database name :c:\winnt\order.mdb
but,there is also the same error,why?
please Mr Wu help me?

Follow Ups:

- Sorry, this works! 小吴 08:01:28 9/23/98 (1)
  - Re: Sorry, this works!(there is the same error) wen 08:39:32 9/23/98 (0)