rdlc

unable to generate RDLC report on client machine after deployment

好久不见. 提交于 2020-12-14 05:51:01
问题 I created an application that uses Microsoft.ReportViewer to show rdlc reports. The application is working fine on the dev. machine. now I am trying to deploy it on a client machine (windows 7) but when I generate the report nothing happens. Nothing at all. No error message and no exception. I am guessing this is due to missing Microsoft.ReportViewer.Winforms.dll/or framework?? I have set copyLocal=true for this dll but still no luck. what is the issue? After putting message boxes at

unable to generate RDLC report on client machine after deployment

北城余情 提交于 2020-12-14 05:47:52
问题 I created an application that uses Microsoft.ReportViewer to show rdlc reports. The application is working fine on the dev. machine. now I am trying to deploy it on a client machine (windows 7) but when I generate the report nothing happens. Nothing at all. No error message and no exception. I am guessing this is due to missing Microsoft.ReportViewer.Winforms.dll/or framework?? I have set copyLocal=true for this dll but still no luck. what is the issue? After putting message boxes at

C#WinForm中追加报表以及图片的功能

强颜欢笑 提交于 2020-08-10 20:23:57
效果图片: 分步解析实现过程: 一.新建报表所需要的文件以及类: 1.新建一个WindowForm项目WindowsFormsReport; 2. 添加Entity文件夹,并添加StudentEntity.cs类; public class StudentEntity { /// <summary> /// 姓名 /// </summary> public string StuName { get; set; } /// <summary> /// 年龄 /// </summary> public string StuAge { get; set; } /// <summary> /// 学生住址 /// </summary> public string StuAddress { get; set; } /// <summary> /// 身高 /// </summary> public string StuHeight { get; set; } /// <summary> /// 体重 /// </summary> public string StuWeight { get; set; } /// <summary> /// 学生电话 /// </summary> public string StuPhone { get; set; } } 3.添加Report文件夹

RDLC how can I make text justify?

杀马特。学长 韩版系。学妹 提交于 2020-07-20 10:17:06
问题 I'm working in a windows application and I want that in my RDLC reports text to be justified. 回答1: I made a function to convert text in a list of strings. You can use a table without header to show it like a justifyed paraghaph. public static List<string> GetText(string text, int width) { string[] palabras = text.Split(' '); StringBuilder sb1 = new StringBuilder(); StringBuilder sb2 = new StringBuilder(); int length = palabras.Length; List<string> resultado = new List<string>(); for (int i =

RDLC how can I make text justify?

蹲街弑〆低调 提交于 2020-07-20 10:15:29
问题 I'm working in a windows application and I want that in my RDLC reports text to be justified. 回答1: I made a function to convert text in a list of strings. You can use a table without header to show it like a justifyed paraghaph. public static List<string> GetText(string text, int width) { string[] palabras = text.Split(' '); StringBuilder sb1 = new StringBuilder(); StringBuilder sb2 = new StringBuilder(); int length = palabras.Length; List<string> resultado = new List<string>(); for (int i =

Visual studio 2015 community report viewer version 12 Error getting extra margin using c#

有些话、适合烂在心里 提交于 2020-06-25 18:42:08
问题 I am using Visual studio 2015 community report viewer version 12 to show rdlc reports in my c# project. here is normal A4 page report its works fine for windows xp, vista, win 7 on client PCs but when same application is installed on Windows 10 64 bit then I am facing problem like below as you can see in above image there are unnecessary margins are coming from right and bottom side as well as font size also reduced. but when I export report to PDF then there is no problem in generated PDF

ReportViewer Win32Exception (0x80004005): 创建窗口句柄时出错

守給你的承諾、 提交于 2020-05-01 03:15:04
System.ComponentModel.Win32Exception (0x80004005): 创建窗口句柄时出错。 在 System.Windows.Forms.NativeWindow.CreateHandle(CreateParams cp) 在 System.Windows.Forms.Control.CreateHandle() 在 System.Windows.Forms.TextBoxBase.CreateHandle() 在 System.Windows.Forms.Control.CreateControl(Boolean fIgnoreVisible) 在 System.Windows.Forms.Control.CreateControl() 在 System.Windows.Forms.Control.SetVisibleCore(Boolean value) 在 Microsoft.Reporting.WinForms.WinRSviewer.ShowMessage(String text, Boolean enabled) 在 Microsoft.Reporting.WinForms.ReportViewer.UpdateUIState(Exception e) 在 Microsoft.Reporting.WinForms.ReportViewer

ASP.Net MVC——使用 ITextSharp 完美解决HTML转PDF(中文也可以)

孤者浪人 提交于 2020-04-15 12:58:04
【推荐阅读】微服务还能火多久?>>> 前言: 最近在做老师交代的一个在线写实验报告的小项目中,有这么个需求:把学生提交的实验报告(HTML形式)直接转成PDF,方便下载和打印。 以前都是直接用rdlc报表实现的,可这次牵扯到图片,并且更为重要的一点是 PDF的格式得跟学生提交的HMTL页面一样。经过网上查阅资料, 找到了ITextSharp插件。 ITextSharp很强大,但是在处理HMTL中的 img标签时,src中只能是绝对路径。 解决方法我写在了另一篇文章中 正文: ITextSharp就不多介绍了。项目的链接下载链接为 http://files.cnblogs.com/files/zuochengsi-9/H%E8%BD%ACPDF.zip 下开始项目之前得添加 ITextSharp.dll和ITextSharp.xmlworker.dll 后者是解决中文用的 可以从NuGet中下载引用,具体方法就不介绍了。网上很多解决方案。 项目结构图: 下面先说下主要操作: 步骤:1、将本地的某个视图转成字符串。 2、将字符串整合成PDF的文档,并返回byte数组。 3、讲比特流写到HTTP内容主体的二进制流中去。 视图转字符串代码: 首先新建两个类,转字符串的逻辑主要在RenderViewToString方法中。 public class HtmlViewRenderer {

An error occurred during local report processing: report definition has an invalid target namespace

妖精的绣舞 提交于 2020-04-11 11:37:39
万恶的An error occurred during local report processing异常 出现这个异常有很多原因,下面介绍一下由于VS版本问题造成这样的异常: The report definition has an invalid target namespace 'http://schemas.microsoft.com/sqlserver/reporting/2016/01/reportdefinition' which cannot be upgraded. 当时修改rdlc报表出现了这个错误 当时是要新增一个rdlc报表模板,我就复制了一个原来的rdlc报表,在原有报表的基础上修改,之后保存完看报表代码发现报表的命名空间变了,从2008变到2016,并且报表代码格式都变了,然后就疯狂报那个错。 解决办法: 将:<Report xmlns="http://schemas.microsoft.com/sqlserver/reporting/2016/01/reportdefinition" xmlns:rd="http://schemas.microsoft.com/SQLServer/reporting/reportdesigner"> 改为:<Report xmlns="http://schemas.microsoft.com/sqlserver