. NET Report loading prompt undefined problem solved

Source: Internet
Author: User

When VB6 is used for report generation, it uses a third-party grid ++ report and is now transferred. net, with the built-in rdlc report, refer to the tutorial of Cui, strictly follow his practice step by step, I tried to avoid several points of attention in the article, after several attempts, the system prompts that the report is undefined. Because the report prompt information is not detailed, I don't know where the problem is. I thought it was a problem of passing parameters. Then I simply removed all the parameters, but the problem still exists.

The cause is that the report path is loaded. An absolute path is added to load the report:

Reportviewer1.localreport. reportpath = "F: \ Project project \ IDC Charging System (net individual edition) \ IDC charging individual implementation \ IDC charging individual edition \ ui_reportofday.rdlc"

Loaded successfully.

The program must use a relative path. You can use application. startuppath obtains the file path of the executable program, VB. the default program running path is the bin directory under the project folder, but the rdlc file of the report is under the root directory. The solution is to copy the rdlc file of the report to the bin directory .. I didn't come up with a good solution, but I ran it perfectly now ~


Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.