|
-
Jul 23rd, 2004, 02:08 AM
#1
Thread Starter
Member
Connect CR To SQL Without DSN !
I am using CR 8.5 n SQL server 2k. I want to create a DSNLess report. I have tried using the Data Explorer -> More Data Sources -> Microsoft Sql Server Option. The report by itself works fine but I don't know how to connect a dsnless report from my vbcode [CrViewer control] .
Any Help will really be appriated.
Thanx.
- Marjo
-
Jul 26th, 2004, 08:23 AM
#2
Hyperactive Member
I use OLE DB (ADO) as a data source when designing my reports (CR 9).
Here's in part how I call my report on my form:
VB Code:
'+-----------------+
'| SQL SERVER INFO |
'+-----------------+
crConnectionInfo = New ConnectionInfo
With crConnectionInfo
.ServerName = "MYSQLSERVER"
.DatabaseName = "MYDATABASE"
.UserID = "MYUSERID"
.Password = "MYPASSWORD"
End With
Hope this helps.
-
Jul 27th, 2004, 04:24 AM
#3
Thread Starter
Member
crConnectionInfo = New ConnectionInfo
With crConnectionInfo
.ServerName = "MYSQLSERVER"
.DatabaseName = "MYDATABASE"
.UserID = "MYUSERID"
.Password = "MYPASSWORD"
End With
Thanks ARPrince for replying. I am using 8.5 and I couldn't find the connectionInfo. Can you please provide me more details.
-
Jul 27th, 2004, 08:10 AM
#4
Hyperactive Member
I don't use CR 8.5 so I may not be in the best position to assist you. I was thinking it would be more or less the same but It may not be supported by CR 8.5 afterall.
-
Jul 31st, 2004, 04:23 AM
#5
Thread Starter
Member
Thanks ARPrince once again.
Can anybody else help me please, I am desperately searching for a solution to this problem.
-
Aug 1st, 2004, 08:39 PM
#6
Here is my DSN-less connection String when I am using VB6, CR8.5 and SQL 7:
VB Code:
ConnectString = "Provider=SQLOLEDB;DATA SOURCE=192.168.XXX.XX;Initial Catalog=Database Name;USER ID=UserName;Password=Password"
Good Luck
Regards,
Mark
Please remember to rate posts! Rate any post you find helpful. Use the link to the left - "Rate this Post". Please use [highlight='vb'] your code goes in here [/highlight] tags when posting code. When a question you asked has been resolved, please go to the top of the original post and click "Thread Tools" then select "Mark Thread Resolved."
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|