本文整理汇总了C#中FlexCelPdfExport.EndExport方法的典型用法代码示例。如果您正苦于以下问题:C# FlexCelPdfExport.EndExport方法的具体用法?C# FlexCelPdfExport.EndExport怎么用?C# FlexCelPdfExport.EndExport使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类FlexCelPdfExport
的用法示例。
在下文中一共展示了FlexCelPdfExport.EndExport方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: ViewPDF
/// <summary>
/// Hiển thị báo cáo dạng pdf
/// </summary>
/// <param name="MaND">Mã người dùng</param>
/// <param name="iID_MaPhongBan">Mã phòng ban</param>
/// <returns></returns>
public ActionResult ViewPDF(string MaND, string iID_MaPhongBan,string iThang)
{
HamChung.Language();
ExcelFile xls = CreateReport(Server.MapPath(sFilePath), MaND, iID_MaPhongBan,iThang);
using (FlexCelPdfExport pdf = new FlexCelPdfExport())
{
pdf.Workbook = xls;
using (MemoryStream ms = new MemoryStream())
{
pdf.BeginExport(ms);
pdf.ExportAllVisibleSheets(false, "BaoCao");
pdf.EndExport();
ms.Position = 0;
return File(ms.ToArray(), "application/pdf");
}
}
}
示例2: ViewPDF
public ActionResult ViewPDF(String iID_MaDotCapPhat, String iLoai, String sNoiDung)
{
HamChung.Language();
String DuongDan = "";
if (iLoai == "1")
DuongDan = sFilePath_ThanhToan;
else
DuongDan = sFilePath_TamUng;
ExcelFile xls = CreateReport(Server.MapPath(DuongDan), iID_MaDotCapPhat, iLoai, sNoiDung);
using (FlexCelPdfExport pdf = new FlexCelPdfExport())
{
pdf.Workbook = xls;
using (MemoryStream ms = new MemoryStream())
{
pdf.BeginExport(ms);
pdf.ExportAllVisibleSheets(false, "BaoCao");
pdf.EndExport();
ms.Position = 0;
return File(ms.ToArray(), "application/pdf");
}
}
return null;
}
示例3: ViewPDF
/// <summary>
/// Xem PDF
/// </summary>
/// <param name="NamLamViec"></param>
/// <param name="iID_MaDonVi"></param>
/// <returns></returns>
public ActionResult ViewPDF(String MaND, String iID_MaDonVi, String iID_MaDanhMuc, String sLNS, String iID_MaTrangThaiDuyet, String Check)
{
HamChung.Language();
String sFilePath = "";
if (Check == "off")
{
sFilePath = "/Report_ExcelFrom/DuToan/rptDT_ChiNganSachSD_II_02.xls";
}
else
{
sFilePath = "/Report_ExcelFrom/DuToan/rptDT_Chi_SuDungNganSachNam.xls";
}
ExcelFile xls = CreateReport(Server.MapPath(sFilePath), MaND, iID_MaDonVi, iID_MaDanhMuc, sLNS, iID_MaTrangThaiDuyet, Check);
using (FlexCelPdfExport pdf = new FlexCelPdfExport())
{
pdf.Workbook = xls;
using (MemoryStream ms = new MemoryStream())
{
pdf.BeginExport(ms);
pdf.ExportAllVisibleSheets(false, "BaoCao");
pdf.EndExport();
ms.Position = 0;
return File(ms.ToArray(), "application/pdf");
}
}
return null;
}
示例4: ViewPDF
//public ActionResult ViewPDF(String MaND, String sLNS, String iID_MaDonVi, String iID_MaDot,
// String iID_MaPhongBan, String LoaiTongHop)
/// <summary>
/// Xuất file pdf báo cáo dự toán tổng hợp chọn phòng ban đơn vị
/// </summary>
/// <param name="maND">Mã người dùng</param>
/// <param name="sLNS">Loại ngân sách</param>
/// <param name="maDonVi">Mã đơn vị</param>
/// <param name="maDot">Mã đợt cấp phát</param>
/// <param name="maPhongBan">Mã phòng ban</param>
/// <param name="loaiBaoCao">Chọn báo cáo xuất ra là tổng hợp hay chi tiết</param>
/// <returns></returns>
public ActionResult ViewPDF(String maND, String sLNS, String maDonVi, String maDot,
String maPhongBan, String loaiBaoCao)
{
HamChung.Language();
String sDuongDan = "";
//Xuất báo cáo chi tiết
if (loaiBaoCao == "ChiTiet")
{
sDuongDan = sFilePath_ChiTiet;
}
//Xuất báo cáo tổng hợp
else
{
sDuongDan = sFilePath_TongHop;
}
ExcelFile xls = CreateReport(Server.MapPath(sDuongDan), maND, sLNS, maDonVi, maDot, maPhongBan, loaiBaoCao);
using (FlexCelPdfExport pdf = new FlexCelPdfExport())
{
pdf.Workbook = xls;
using (MemoryStream ms = new MemoryStream())
{
pdf.BeginExport(ms);
pdf.ExportAllVisibleSheets(false, "BaoCao");
pdf.EndExport();
ms.Position = 0;
return File(ms.ToArray(), "application/pdf");
}
}
}
示例5: ExportToPDF
public clsExcelResult ExportToPDF(String MaND, String ThangQuy, String LoaiThang_Quy, String iID_MaDonVi, String iID_MaNhomDonVi, String LuyKe, String iID_MaTrangThaiDuyet, String KhoGiay, String BaoHiem,String iLoai)
{
clsExcelResult clsResult = new clsExcelResult();
HamChung.Language();
String sFilePath = "";
if (KhoGiay == "0")
{
if (BaoHiem == "0" || BaoHiem == "1" || BaoHiem == "2")
{
sFilePath = "/Report_ExcelFrom/BaoHiem/rptBH_TongQuyetToan1.xls";
}
else if (BaoHiem == "3")
{
sFilePath = "/Report_ExcelFrom/BaoHiem/rptBH_TongQuyetToanCN.xls";
}
else if (BaoHiem == "4")
{
sFilePath = "/Report_ExcelFrom/BaoHiem/rptBH_TongQuyetToanDV.xls";
}
else
{
sFilePath = "/Report_ExcelFrom/BaoHiem/rptBH_TongQuyetToanTH.xls";
}
}
else
{
if (BaoHiem == "0" || BaoHiem == "1" || BaoHiem == "2")
{
sFilePath = "/Report_ExcelFrom/BaoHiem/rptBH_TongQuyetToan1A3.xls";
}
else if (BaoHiem == "3")
{
sFilePath = "/Report_ExcelFrom/BaoHiem/rptBH_TongQuyetToanCNA3.xls";
}
else if (BaoHiem == "4")
{
sFilePath = "/Report_ExcelFrom/BaoHiem/rptBH_TongQuyetToanDVA3.xls";
}
else
{
sFilePath = "/Report_ExcelFrom/BaoHiem/rptBH_TongQuyetToanTH.xls";
}
}
ExcelFile xls = CreateReport(Server.MapPath(sFilePath), MaND, ThangQuy, LoaiThang_Quy, iID_MaDonVi, iID_MaNhomDonVi, LuyKe, iID_MaTrangThaiDuyet, KhoGiay, BaoHiem,iLoai);
using (FlexCelPdfExport pdf = new FlexCelPdfExport())
{
pdf.Workbook = xls;
using (MemoryStream ms = new MemoryStream())
{
pdf.BeginExport(ms);
pdf.ExportAllVisibleSheets(false, "AA");
pdf.EndExport();
ms.Position = 0;
clsResult.FileName = "Test.pdf";
clsResult.type = "pdf";
clsResult.ms = ms;
return clsResult;
}
}
}
示例6: ViewPDF
/// <summary>
/// Hiển thị báo cáo theo định dạng file PDF
/// </summary>
/// <param name="Nam">Năm làm việc</param>
/// <param name="MaDN">Mã doanh nghiệp</param>
/// <returns></returns>
public ActionResult ViewPDF(String Quy, String Nam, String MaDN)
{
HamChung.Language();
ExcelFile xls = CreateReport(Server.MapPath(sFilePath), Quy, Nam, MaDN);
using (FlexCelPdfExport pdf = new FlexCelPdfExport())
{
pdf.Workbook = xls;
using (MemoryStream ms = new MemoryStream())
{
pdf.BeginExport(ms);
pdf.ExportAllVisibleSheets(false, "BaoCao");
pdf.EndExport();
ms.Position = 0;
return File(ms.ToArray(), "application/pdf");
}
}
return null;
}
示例7: ViewPDF
/// <summary>
/// Xem File PDF
/// </summary>
/// <param name="NamLamViec"></param>
/// <param name="ThangLamViec"></param>
/// <param name="iID_MaDonVi"></param>
/// <returns></returns>
public ActionResult ViewPDF(String NgoaiTe, string vidDenNgay)
{
//ViewData["bBaoCaoTH"] = "False";
String DuongDanFile = sFilePath;
// DateTime dNgay = Convert.ToDateTime(CommonFunction.LayNgayTuXau(vidDenNgay));
ExcelFile xls = CreateReport(Server.MapPath(DuongDanFile), NgoaiTe, vidDenNgay);
using (FlexCelPdfExport pdf = new FlexCelPdfExport())
{
pdf.Workbook = xls;
using (MemoryStream ms = new MemoryStream())
{
pdf.BeginExport(ms);
pdf.ExportAllVisibleSheets(false, "BaoCao");
pdf.EndExport();
ms.Position = 0;
return File(ms.ToArray(), "application/pdf");
}
}
return null;
}
示例8: ExportToPDF
public clsExcelResult ExportToPDF(String iID_MaTrangThaiDuyet, String iID_MaDonVi, String dNgayCapPhat, String iDM_MaLoaiCapPhat, String LuyKe, String LoaiBaoCao)
{
HamChung.Language();
String DuongDan = "";
if (LoaiBaoCao == "Muc")
{
DuongDan = sFilePathMuc;
}
else if (LoaiBaoCao == "TieuMuc")
{
DuongDan = sFilePathTieuMuc;
}
else
{
DuongDan = sFilePathNganh;
}
clsExcelResult clsResult = new clsExcelResult();
ExcelFile xls = CreateReport(Server.MapPath(DuongDan), iID_MaTrangThaiDuyet, iID_MaDonVi, dNgayCapPhat, iDM_MaLoaiCapPhat, LuyKe, LoaiBaoCao);
using (FlexCelPdfExport pdf = new FlexCelPdfExport())
{
pdf.Workbook = xls;
using (MemoryStream ms = new MemoryStream())
{
pdf.BeginExport(ms);
pdf.ExportAllVisibleSheets(false, "AA");
pdf.EndExport();
ms.Position = 0;
clsResult.FileName = "Test.pdf";
clsResult.type = "pdf";
clsResult.ms = ms;
return clsResult;
}
}
}
示例9: ViewPDF
/// <summary>
/// Xuất file PDF quyết toán của từng đơn vị
/// </summary>
/// <param name="MaND">Mã người dùng</param>
/// <param name="iThang_Quy">Quý</param>
/// <param name="sLNS">Loại ngân sách</param>
/// <param name="iID_MaDonVi">Mã đơn vị</param>
/// <param name="iID_MaNamNganSach">Năm ngân sách</param>
/// <param name="MaPhongBan">Mã phòng ban</param>
/// <returns></returns>
public ActionResult ViewPDF(String MaND, String iThang_Quy, String sLNS, String iID_MaDonVi, String iID_MaNamNganSach, String MaPhongBan)
{
HamChung.Language();
String sDuongDan = "";
sDuongDan = EXCEL_FILE_PATH;
ExcelFile xls = CreateReport(Server.MapPath(sDuongDan), MaND, sLNS, iThang_Quy, iID_MaDonVi, iID_MaNamNganSach, MaPhongBan);
using (FlexCelPdfExport pdf = new FlexCelPdfExport())
{
pdf.Workbook = xls;
using (MemoryStream ms = new MemoryStream())
{
pdf.BeginExport(ms);
pdf.ExportAllVisibleSheets(false, "BaoCao");
pdf.EndExport();
ms.Position = 0;
return File(ms.ToArray(), "application/pdf");
}
}
}
示例10: ViewPDF
public ActionResult ViewPDF(String iThang, String iID_MaDonVi, String UserName, String iID_MaTrangThaiDuyet)
{
HamChung.Language();
string lang = "vi-VN";
System.Threading.Thread.CurrentThread.CurrentCulture = System.Globalization.CultureInfo.CreateSpecificCulture(lang);
System.Threading.Thread.CurrentThread.CurrentUICulture = System.Globalization.CultureInfo.CreateSpecificCulture(lang);
ExcelFile xls = CreateReport(Server.MapPath(sFilePath), iThang, iID_MaDonVi, UserName, iID_MaTrangThaiDuyet);
using (FlexCelPdfExport pdf = new FlexCelPdfExport())
{
pdf.Workbook = xls;
using (MemoryStream ms = new MemoryStream())
{
pdf.BeginExport(ms);
pdf.ExportAllVisibleSheets(false, "BaoCao");
pdf.EndExport();
ms.Position = 0;
return File(ms.ToArray(), "application/pdf");
}
}
return null;
}
示例11: ViewPDF
public ActionResult ViewPDF(String iNam, String iThang,String optThu,String optTamUng,String optTra,String KhoGiay)
{
HamChung.Language();
String DuongDan = "";
if (KhoGiay == "1") DuongDan = sFilePath_a3;
else DuongDan = sFilePath_a4;
ExcelFile xls = CreateReport(Server.MapPath(DuongDan), iNam, iThang, optThu, optTamUng, optTra,KhoGiay);
using (FlexCelPdfExport pdf = new FlexCelPdfExport())
{
pdf.Workbook = xls;
using (MemoryStream ms = new MemoryStream())
{
pdf.BeginExport(ms);
pdf.ExportAllVisibleSheets(false, "BaoCao");
pdf.EndExport();
ms.Position = 0;
return File(ms.ToArray(), "application/pdf");
}
}
return null;
}
示例12: ViewPDF
/// <summary>
/// Hiển thị báo cáo theo định dạng PDF
/// </summary>
/// <param name="NamLamViec"></param>
/// <param name="iID_MaDonVi"></param>
/// <returns></returns>
public ActionResult ViewPDF(String MaND, String iQuy, String bTrongKy, String iID_MaDoanhNghiep, String iLoai, String DVT)
{
HamChung.Language();
String sDuongDan = "";
if (iLoai == "0")
{
sDuongDan = sFilePath_HoSoDoanhNghiep;
}
else if(iLoai=="4")
{
sDuongDan = sFilePath_Loai4;
}
else
{
sDuongDan = sFilePath;
}
ExcelFile xls = CreateReport(Server.MapPath(sDuongDan), MaND, iQuy, bTrongKy, iID_MaDoanhNghiep, iLoai, DVT);
using (FlexCelPdfExport pdf = new FlexCelPdfExport())
{
pdf.Workbook = xls;
using (MemoryStream ms = new MemoryStream())
{
pdf.BeginExport(ms);
pdf.ExportAllVisibleSheets(false, "BaoCao");
pdf.EndExport();
ms.Position = 0;
return File(ms.ToArray(), "application/pdf");
}
}
return null;
}
示例13: ExportToPDF
/// <summary>
/// Xuất ra PDF
/// </summary>
/// <param name="NamLamViec"></param>
/// <param name="iID_MaDonVi"></param>
/// <param name="DotPhanBo"></param>
/// <returns></returns>
public clsExcelResult ExportToPDF(String iID_MaDonVi, String DotPhanBo, String iID_MaTrangThaiDuyet)
{
String DuongDanFile = sFilePath;
clsExcelResult clsResult = new clsExcelResult();
ExcelFile xls = CreateReport(Server.MapPath(DuongDanFile), iID_MaDonVi, DotPhanBo,iID_MaTrangThaiDuyet);
using (FlexCelPdfExport pdf = new FlexCelPdfExport())
{
pdf.Workbook = xls;
using (MemoryStream ms = new MemoryStream())
{
pdf.BeginExport(ms);
pdf.ExportAllVisibleSheets(false, "AA");
pdf.EndExport();
ms.Position = 0;
clsResult.FileName = "Test.pdf";
clsResult.type = "pdf";
clsResult.ms = ms;
return clsResult;
}
}
}
示例14: ViewPDF
public ActionResult ViewPDF(String MaND, String iID_MaTrangThaiDuyet, String iNgay, String iThang, String DonViTinh, String NoiDung)
{
HamChung.Language();
String DuongDanFile = "";
if (NoiDung == "-1")
{
DuongDanFile = sFilePath;
}
else if (NoiDung == "0")
{
DuongDanFile = sFilePath_NT;
}
else
{
DuongDanFile = sFilePath_TV;
}
ExcelFile xls = CreateReport(Server.MapPath(DuongDanFile), MaND, iID_MaTrangThaiDuyet, iNgay, iThang, DonViTinh, NoiDung);
using (FlexCelPdfExport pdf = new FlexCelPdfExport())
{
pdf.Workbook = xls;
using (MemoryStream ms = new MemoryStream())
{
pdf.BeginExport(ms);
pdf.ExportAllVisibleSheets(false, "BaoCao");
pdf.EndExport();
ms.Position = 0;
return File(ms.ToArray(), "application/pdf");
}
}
return null;
}
示例15: ViewPDF
/// <summary>
/// Hiện thị báo cáo theo định dạng PDF
/// </summary>
/// <param name="iLoaiThang_Quy">0: Chọn tháng | 1: Chọn quý</param>
/// <param name="iThang">Tháng</param>
/// <param name="iQuy">Quý</param>
/// <param name="iNguonNS">Nguồn ngân sách</param>
/// <param name="iMuc_TieuMuc">In đến mức: Mục | Tiểu mục</param>
/// <param name="MaND">Năm</param>
/// <returns></returns>
public ActionResult ViewPDF(String iLoaiThang_Quy, String iThang, String iQuy, String iNguonNS, String iMuc_TieuMuc, String MaND, String iTrangThai)
{
HamChung.Language();
ExcelFile xls = CreateReport(Server.MapPath(sFilePath), iLoaiThang_Quy, iThang, iQuy, iNguonNS, iMuc_TieuMuc, MaND,iTrangThai);
using (FlexCelPdfExport pdf = new FlexCelPdfExport())
{
pdf.Workbook = xls;
using (MemoryStream ms = new MemoryStream())
{
pdf.BeginExport(ms);
pdf.ExportAllVisibleSheets(false, "BaoCao");
pdf.EndExport();
ms.Position = 0;
return File(ms.ToArray(), "application/pdf");
}
}
return null;
}