Wednesday, March 21, 2012

Error 80004005 with MSDE and VB 6

Hello
I am new to SQL Server / MSDE ... Strong with MS Access
I have MSDE loaded on 2 computers, a local computer (Windows XP Home) and on a Windows 2003 Server (WEB Edition). I have simplified the problem by trying to access the database only on the local computer (DEVELOPMENT).
I tried to open a Test Database on the Development computer using the following code snipplet:
Private ObjConn As New adodb.Connection
Private ObjRS As New adodb.Recordset
Private Sub Command1_Click()
On Error GoTo 0
With ObjConn
.ConnectionTimeout = 30
.CommandTimeout = 30
.Provider = "SQLOLEDB"
.ConnectionString = "DRIVER={SQL Server}; Server=Development; Database=Test; UID=sa; PWD="
End With
ObjConn.Open
end sub
I keep getting an error 80004005 -- Invalid character string attribute
I have checked all of the books that I have and looked all over the Internet, but can not figure out what I'm doing wrong ... can anyone offer any help
Thanks in advance
George
From http://www.developmentnow.com/g/100_...er-connect.htm
Posted via DevelopmentNow.com Groups
http://www.developmentnow.com
Remove the "DRIVER={SQL Server};" portion of the connection string.
Arnie Rowland, Ph.D.
Westwood Consulting, Inc
Most good judgment comes from experience.
Most experience comes from bad judgment.
- Anonymous
"George Slamowitz" <GSlamowitz@.COX.NET> wrote in message
news:6d371311-0877-499b-aeb3-c838647b3e2d@.developmentnow.com...
> Hello
> I am new to SQL Server / MSDE ... Strong with MS Access
> I have MSDE loaded on 2 computers, a local computer (Windows XP Home) and
> on a Windows 2003 Server (WEB Edition). I have simplified the problem by
> trying to access the database only on the local computer (DEVELOPMENT).
> I tried to open a Test Database on the Development computer using the
> following code snipplet:
>
> Private ObjConn As New adodb.Connection
> Private ObjRS As New adodb.Recordset
>
> Private Sub Command1_Click()
> On Error GoTo 0
> With ObjConn
> .ConnectionTimeout = 30
> .CommandTimeout = 30
> .Provider = "SQLOLEDB"
> .ConnectionString = "DRIVER={SQL Server}; Server=Development;
> Database=Test; UID=sa; PWD="
> End With
> ObjConn.Open
> end sub
> I keep getting an error 80004005 -- Invalid character string attribute
> I have checked all of the books that I have and looked all over the
> Internet, but can not figure out what I'm doing wrong ... can anyone
> offer any help
> Thanks in advance
> George
> From http://www.developmentnow.com/g/100_...er-connect.htm
> Posted via DevelopmentNow.com Groups
> http://www.developmentnow.com
sql

No comments:

Post a Comment