Excel VBA and C/ODBC 3.70

slapin
Member Posts: 8
Hi,
Hi I have juste developped a great excel 2003 worksheet with VBA witch gets information form an MBS Navision 3.70 French through C/ODBC
It works great, far more eficient than MS Query. (90s than 20 minutes)
However got this pain, that it only works on my developper computer.
I try to install it on same computer but user computer but I cannot make it work:
WinXP SP2 + MBS 3.70 Client + C/ODBC + Office 2003 SP1.
The macro stops on a message in french (sorry) "Erreur d'exécution 3706, impossible de trouver le fournisseur. Il est peut etre mal installé" and then "Erreur d'excution -2147220999 (8000401f9): La méthode Open de l'objet _Connection a échoué".
I try to translate:"Execution Error 3706, Impossible to find the provider. I may be bad installed" and then "Execution Error -2147220999 (8000401f9): The methode Open of object _Connection failed".
The first message does not help me, C/ODBC is correctly installed, because MSQuery works find for the same provider on those workstation.
The second is obvious, Excel hangs on the cnx.Open instruction.
Dim cnx As ADODB.Connection
Dim rst As ADODB.Recordset
Set cnx = New ADODB.Connection
Set rst = New ADODB.Recordset
cnx.ConnectionString = "DRIVER={C/ODBC 32 bit};CSF=Yes;SName=db-server;NType=tcp;UID=query;PWD=whatever;CN=GOODBOY;SERVER=N;IT=a-Z,A-Z,0-9,_;ML=1036"
cnx.Open
Got an idea?
Thanks for your help.
Hi I have juste developped a great excel 2003 worksheet with VBA witch gets information form an MBS Navision 3.70 French through C/ODBC
It works great, far more eficient than MS Query. (90s than 20 minutes)
However got this pain, that it only works on my developper computer.
I try to install it on same computer but user computer but I cannot make it work:
WinXP SP2 + MBS 3.70 Client + C/ODBC + Office 2003 SP1.
The macro stops on a message in french (sorry) "Erreur d'exécution 3706, impossible de trouver le fournisseur. Il est peut etre mal installé" and then "Erreur d'excution -2147220999 (8000401f9): La méthode Open de l'objet _Connection a échoué".
I try to translate:"Execution Error 3706, Impossible to find the provider. I may be bad installed" and then "Execution Error -2147220999 (8000401f9): The methode Open of object _Connection failed".
The first message does not help me, C/ODBC is correctly installed, because MSQuery works find for the same provider on those workstation.
The second is obvious, Excel hangs on the cnx.Open instruction.
Dim cnx As ADODB.Connection
Dim rst As ADODB.Recordset
Set cnx = New ADODB.Connection
Set rst = New ADODB.Recordset
cnx.ConnectionString = "DRIVER={C/ODBC 32 bit};CSF=Yes;SName=db-server;NType=tcp;UID=query;PWD=whatever;CN=GOODBOY;SERVER=N;IT=a-Z,A-Z,0-9,_;ML=1036"
cnx.Open
Got an idea?
Thanks for your help.
0
Comments
-
Try adding 'PPath=...;' to your connection string.
Ex: PPath=C:\Program Files\Microsoft Business Solutions-Navision\Client;
FYI: Here's a list of the C/ODBC connection string options, taken from 'w1w1codbc.pdf':- CSF=[Yes|No]; Specifies whether the driver operates in a client/server environment or stand-alone.
- NType=[tcp|netb]; The name of the network protocol.
- SName=xxx; The name of the server host computer.
- Database=xxx; The name(s) of the database file(s).
- CN=xxx; The company to open.
- OPT=[Text|Integer]; Specifies how the contents of an option field are transferred.
- UID=xxx; The user ID for logging in.
- PWD=xxx; The password for the user ID (UID).
- PPath=xxx; The name of the folder where the program files are located.
- TP=xxx; The name of the folder that will be used to store temporary files.
- QTYesNo=[Yes|No]; Enables or disables query time-out:
- QT=nnn; The number of seconds to elapse before time-out.
- IT=[All Characters|All Except Space|a-z,A-Z,0-9,_|All Except DOT]; Specify the way identifiers are returned to an external application:
- RO=[Yes|No]; Specifies whether access should be read-only.
- CS=nnn; The cache size in KB.
- CC=[Yes|No]; Specifies whether the commit cache should be used.
- BE=[Yes|No]; Specifies whether BLOB fields should be visible from ODBC.
- CD=[Yes|No]; Specifies whether the connection supports closing date.
- ML=nnnn; Specifies a language other than the global language.
0
Categories
- All Categories
- 73 General
- 73 Announcements
- 66.6K Microsoft Dynamics NAV
- 18.7K NAV Three Tier
- 38.4K NAV/Navision Classic Client
- 3.6K Navision Attain
- 2.4K Navision Financials
- 116 Navision DOS
- 851 Navision e-Commerce
- 1K NAV Tips & Tricks
- 772 NAV Dutch speaking only
- 617 NAV Courses, Exams & Certification
- 2K Microsoft Dynamics-Other
- 1.5K Dynamics AX
- 322 Dynamics CRM
- 111 Dynamics GP
- 10 Dynamics SL
- 1.5K Other
- 990 SQL General
- 383 SQL Performance
- 34 SQL Tips & Tricks
- 35 Design Patterns (General & Best Practices)
- 1 Architectural Patterns
- 10 Design Patterns
- 5 Implementation Patterns
- 53 3rd Party Products, Services & Events
- 1.6K General
- 1.1K General Chat
- 1.6K Website
- 83 Testing
- 1.2K Download section
- 23 How Tos section
- 252 Feedback
- 12 NAV TechDays 2013 Sessions
- 13 NAV TechDays 2012 Sessions