且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

无法在 Visual Studio 2010 中打开 .rpt Crystal Reports 文件

更新时间:2023-11-22 13:02:52

我怀疑 .RPT 的文件类型关联已损坏.您可能在安装 Crystal Reports 之前尝试打开 .RPT,但不小心选择了其他东西来打开它.现在它可能会自动错误地打开它们.

I suspect the file-type association for .RPT is broken. You may have tried opening the .RPT before you had Crystal Reports installed and accidentally selected something else to open it. Now it probably automatically opens them incorrectly.

本文介绍了 Windows 版本之间的更改以及如何编辑它们:http://www.technize.com/advanced-file-types-association-in-windows-7/

This article describes changes between Windows versions and how to edit them: http://www.technize.com/advanced-file-types-association-in-windows-7/

也就是说,有一种更快更简单的方法来进行快速测试,以确认这些 .RPT 文件是否有效.

That said, there is a quicker easier way to do a quick test to confirm if those .RPT files are valid.

在 Visual Studio 中,在您的 C# 项目中,执行添加新项目 > 报告 > Crystal Reports",它将启动一个向导,用于将报告添加到您的项目中.发生这种情况时,系统会提示您创建新报告"或从现有文件打开".选择打开现有并浏览到您的 .RPT 文件.这将强制 Crystal Reports 尝试在基于 Visual Studio 的 Crystal Report 设计器中打开此文件.

In Visual Studio, inside your C# project, do an 'Add New Item > Reporting > Crystal Reports' and it will start a wizard for adding reports to your project. When this happens, you'll be prompted to 'create a new report' or to 'open from existing file'. Choose open existing and browse to your .RPT file. This should force Crystal Reports to attempt to open this file in the Visual Studio based Crystal Report designer.

祝你好运.