Crystal Report file not found after Deploy

G

Guest

Hi,

It is the first time I use Crystal Report and I have a issue.
I have a reportfile (Category.rpt) in my winform project.

When I work in debug mode I can load this report without any problem.

Dim rptDocument as new CrystalDecisions.CrystalReports.Engine.ReportDocument
rptDocument.Load("Category.rpt")

After deployement, the program did not find the file (He is looking in the
application data repertory).

How can I :

- Include the rpt file in deployement phase.
- Change my code in order that the load report was fine after deployment?

I have try with path like Application.startupPath, ...

Thanks

Patrick
 
R

Rad [Visual C# MVP]

Hi,

It is the first time I use Crystal Report and I have a issue.
I have a reportfile (Category.rpt) in my winform project.

When I work in debug mode I can load this report without any problem.

Dim rptDocument as new CrystalDecisions.CrystalReports.Engine.ReportDocument
rptDocument.Load("Category.rpt")

After deployement, the program did not find the file (He is looking in the
application data repertory).

How can I :

- Include the rpt file in deployement phase.
- Change my code in order that the load report was fine after deployment?

I have try with path like Application.startupPath, ...

Thanks

Patrick

Check the build action of the rpt file -- make sure it is content
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top