Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Passing an ADO Recordset from VFP6 to Crystal Reports

Status
Not open for further replies.

LeonelSanchezJr

Programmer
Jan 26, 2001
522
US
I am creating a record set with the following code and then I want to run a Crystal Report right afterward and have Crystal Reports use that record set. What code do I need to implement in between the following to parargraphs of code?

********************************************************
* code to create object and query sql
oAdo = CreateObject('AdoDb.Connection')
oAdor = CreateObject('Ador.Recordset')
oAdo.ConnectionString = [Provider=SQLoledb;data source= EGLStalDevSQL01;User ID =le;Password=;Connect Timeout=3]
oADO.Open
oAdo.DefaultDatabase = 'Talon_Dot_net'
Ador = oAdo.Execute("exec Hawb_SelectHawb 'TESTHAWBGES001'")



************************************************************
* code to preview Crystal report
oCRApp = createobject("crystal.crpe.application")
oRep = oCRApp.OpenReport("d:\leo\HAWB Air Waybill.rpt")
oRep.Preview
wait
***********************************************************


Thanks




 
Hmm I dont know I dont use Crystal but do you not need a Clientside recordset or can Crystal use a serverside one?
Do you have to set any reference to the ADO library in Crystal? Noone answered so I'm just throwing up guesses like a druken sailor after eating too much that nite John Durbin
john@johndurbin.com
MCP Visual FoxPro
ICQ VFP ActiveList #73897253
 
Hi!

Leonelsanchezjr, you need to look into the documentation for Crystal Repors or post this question to another forum. Your question is about functionality of the CR ActiveX object and ADO objects that is out of scope of this forum.



Vlad Grynchyshyn
vgryn@softserve.lviv.ua
The professional level of programmer could be determined by level of stupidity of his/her bugs
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top