By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
443,865 Members | 1,725 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 443,865 IT Pros & Developers. It's quick & easy.

Password problem with AS400 from Windows 2000 (ADO)

P: n/a
I have a VB6 program that uses ADO to an AS400 running v4r5. The
following code works fine on a Windows NT 4 machine, but prompts me
for a user and password on Windows 2000. The Win2000 machine has
Client Access Express, the NT machine has Client Access.

Const CSTRING_400 = "Provider=MSDASQL.1;" _
& "Password=MyPass;" _
& "Persist Security Info=True;" _
& "User ID=MyUser;" _
& "Data Source =MyAS400"
Dim c400 As New ADODB.Connection

c400.Open CSTRING_400
-----------
The above uses Microsoft's (deprecated) generic ADO driver. I've tried
using IBM's Client Access driver as follows:

Const CSTRING_400 = "Provider=IBMDA400;" _
& "Password=MyPass;" _
& "User ID=MyUser;" _
& "Data Source=MyAS400;" _
& "Transport Product=Client Access;" _
& "SSL=DEFAULT"

When I do this, it gets past the Open statement, but dies on the first
query with:

Run-time error '-2147467259 (800040005)':

CWBDB0001 - Connection handle failed in attempt to contact server
(System MyAS400)

-----------
More information. Using MSDASQL on Windows 2000, if I enter the
password, the program works fine. And if I re-run it, it doesn't ask
me again until I've rebooted.

Any thoughts? I've been struggling with this for a long time.

LB
Jul 17 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
Did u ever get this resolved? I am having a similar problem and have
not been able to locate much info on this. I get past the open
statement and then I get the exact same error on the first query.

lb****@precision-valve.com (Larry Blake) wrote in message news:<b6**************************@posting.google. com>...
I have a VB6 program that uses ADO to an AS400 running v4r5. The
following code works fine on a Windows NT 4 machine, but prompts me
for a user and password on Windows 2000. The Win2000 machine has
Client Access Express, the NT machine has Client Access.

Const CSTRING_400 = "Provider=MSDASQL.1;" _
& "Password=MyPass;" _
& "Persist Security Info=True;" _
& "User ID=MyUser;" _
& "Data Source =MyAS400"
Dim c400 As New ADODB.Connection

c400.Open CSTRING_400
-----------
The above uses Microsoft's (deprecated) generic ADO driver. I've tried
using IBM's Client Access driver as follows:

Const CSTRING_400 = "Provider=IBMDA400;" _
& "Password=MyPass;" _
& "User ID=MyUser;" _
& "Data Source=MyAS400;" _
& "Transport Product=Client Access;" _
& "SSL=DEFAULT"

When I do this, it gets past the Open statement, but dies on the first
query with:

Run-time error '-2147467259 (800040005)':

CWBDB0001 - Connection handle failed in attempt to contact server
(System MyAS400)

-----------
More information. Using MSDASQL on Windows 2000, if I enter the
password, the program works fine. And if I re-run it, it doesn't ask
me again until I've rebooted.

Any thoughts? I've been struggling with this for a long time.

LB

Jul 17 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.