如何在Asp.Net中打印 [英] How Do I Print In Asp.Net

查看:92
本文介绍了如何在Asp.Net中打印的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

打印个人信息的最佳解决方案是什么?例如,我想从设计中打印数据库中的学生证。什么是最好的方法?香港专业教育学院尝试使用javascript函数。但我在设计页面时遇到问题。



what is the best solution to print individual information?Eg i want to print student card from database with design. what is the best approach?ive tried using javascript function. but i have problem in designing the page.

function PrintPanel() {
          var panel = document.getElementById("<%=FormView1.ClientID %>");
          var printWindow = window.open('', '', 'height=400,width=800');
          printWindow.document.write('<html><head><title>Print Student Card</title>');
          printWindow.document.write('</head><body >');
          printWindow.document.write(panel.innerHTML);
          printWindow.document.write('</body></html>');
          printWindow.document.close();
          setTimeout(function () {
              printWindow.print();
          }, 500);

推荐答案

http://www.c-sharpcorner.com/uploadfile/rahul4_saxena/ print-in-Asp-Net / [ ^ ]


考虑使用报告工具,例如MS随VS提供的免费RDLC报告格式。更多细节& http://www.gotreportviewer.com 上的信息
Consider using a reporting tool like the free RDLC report format shipped by MS with VS. Further details & info at http://www.gotreportviewer.com


这篇关于如何在Asp.Net中打印的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆