I have an MS-Access 2000 application that is connected to a MS-SQL
Server 2000 backend by linking tables through a DSN-Less connection.
No problems at all with that part.
This application executes various Crystal Reports that have their own
built in SQL. These reports have no need for the MS-Access Linked
tables and can function stand-alone against MS-SQL.
According to Crystal Reports you can connect a report to MS-SQL with a
DSN-Less connection by setting the internal report parameters as so:
5. Type in the connection information.
Example:
Driver=SQL Server;
Server=SQL Server Production Server;
Database=Xtreme;
UID=SalesRep;
PWD=password1234
Yes that does work from within Crystal Reports but I want my MS-Access
(VBA code) to tell the report how to connect so I use the following
code:
[Form_Report Form].crxReport.Database.Tables.Item(1).SetLogOnInfo _
strServerName, _
strDatabase, _
strUserID, _
strPassword
From everything I can read, I don't have a parameter for "Driver" like
they show in their "manual setup" instructions. Unfortunately since
I'm not specifying the Driver in the above setup code I get an error
"datasource name not found and no default driver specified"
How do I tell Crystal Reports how to connect to this database using a
DSN-Less connection from VBA code?
Thanks