using System;
using System.Data;
using System.Configuration;
using System.Windows.Forms;
using iTextSharp;
using iTextSharp.text;
using iTextSharp.text.pdf;
using System.IO;
using System.Data.SqlClient;
[itextsharp.dll]
public partial class GrdvTOpdf
{
#region ConvertGrdiViewToPDF() -> 换GridView为PDF文档
///
/// 转换GridView为PDF文档 ///
/// GridView
/// 目标PDF文件名字
/// 字体所在路径
/// 字体大小
/// 返回调用是否成功
public void ConvertGrdiViewToPDF(DataGridView datagridview)
{
///设置导出字体
///
string FontPath ="C://WINDOWS//Fonts//simsun.ttc,1";
int FontSize = 12;
///
Boolean cc=false;
string strFileName;
SaveFileDialog savFile = new SaveFileDialog();
savFile.Filter