• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 362
  • Last Modified:

Exporting a Crystal Report to HTML from within a VB6 Application

I have a crystal Reports application that is designed to run each night and move a couple of PDF files out to a network location each night, This works fine with the PDFs usign the code in the top section. I now want to add in another report that get moved out to the same locatoin but in the HTML format. When I run this code I recieve an error and it stops at the the "crptBBCadStatus.Export (False)" line. Can anybody spot what I am going wrong with the second set of code?

'This code works fine.....
crptCitations.ExportOptions.PDFExportAllPages = True
crptCitations.ExportOptions.FormatType = crEFTPortableDocFormat
crptCitations.ExportOptions.DiskFileName = ("\\Reports\citations.pdf")
crptCitations.ExportOptions.DestinationType = crEDTDiskFile
crptCitations.Export (False)
'This code has a problem, and won't export like the above....
crptBBCadStatus.ExportOptions.HTMLFileName = ("\\reports\pdf\BBCadStatus.html")
'I tried it with and without the above line
crptBBCadStatus.ExportOptions.FormatType = crEFTHTML32Standard
crptBBCadStatus.ExportOptions.DiskFileName = ("\\Reports\pdf\BBCadStatus.html")
crptBBCadStatus.ExportOptions.DestinationType = crEDTDiskFile
crptBBCadStatus.Export (False)
'If I take the above (False) away I get a naming dialog box.
  • 2
  • 2
1 Solution
What is the error?

Do you have permission to write to the pdf directory?

Can you export the report using the pdf code?

Do you have the HTML export driver installed?

DavidNPDAuthor Commented:
OK I am a little lost here, I just went in to run it again to give you the error and it is running perfectly. Let me look at this some more and see what I changed.
DavidNPDAuthor Commented:
Must have just been a typo, I had checked all of your list already. Seems that it started working. Not sure why... Thanks for your reponse.

Glad I could help

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

  • 2
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now