Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Report SendtoExcel Routine
Message
From
02/11/2004 23:05:15
June Kendrick
Kendrick Associates, Inc.
New York, United States
 
General information
Forum:
Visual FoxPro
Category:
The Mere Mortals Framework
Miscellaneous
Thread ID:
00955303
Message ID:
00957448
Views:
14
Dan,

That would be great if you could do so.

Thanks,

June

>June,
>
>I recall adding some code to minimize the OLE errors that we were getting when exporting to Excel. If you are interested I can send you the code on Monday.
>
>-Dan
>
>>The problem with getting a printed report instead of having it in Excel has been solved.
>>
>>I hadn't set up the report properly (didn't use the template), so it wasn't being sent to Excel in the DataEnvironment.Init.
>>
>>I am still getting an OLE 0x error if there isn't an Excel instance open when I try to send it to Excel.
>>
>>June
>>
>>>More:
>>>
>>>If I have an instance of Excel running, then I don't get the error, but what I do get is the report printed out.
>>>
>>>The comments at the end of the cReportsObj.SendtoExcel routine don't agree with what is coded:
>>>
>>>*--- Run the report, which is only used to load
>>>*--- and process the data, copies the cursor
>>>*--- to the specified Excel file name then tells
>>>*--- Excel to load the file
>>>*----------------------------------------------
>>>IF VARTYPE(This.oExcel) == 'O'
>>> REPORT FORM (lcFile) TO PRINTER PROMPT NOCONSOLE
>>>ENDIF
>>>
>>>Any thoughts on how to make this work?
>>>
>>>Thanks.
>>>
>>>June
>>>
>>>>I'm checking out the reporting routines in the cReportsObj bizobj, and am having a problem with SendtoExcel. When I try it, I get "OLE Error code 0x" when it checks to see if an Excel app is running (cOLEBaseExcel.AppRunning), or when it tries to get an instance /create a new instance of the Excel object (cOLEBaseExcel.GetCurrentInstance). In both cases, it is on a = GETOBJECT( , this.cOLERegName) statement. This.cOLERegName contains Excel.Application.
>>>>
>>>>Any ideas as to what might be wrong?
>>>>
>>>>Thanks,
>>>>
>>>>June
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform