Jump to content

Search the Community

Showing results for tags 'c\# export pdf'.

The search index is currently processing. Current results may not be complete.


More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • Am
    • Pengumuman
    • Cadangan & Laporan
    • Members Helpdesk
  • Sistem Operasi
    • Windows
    • Linux & *nix
    • Macintosh
    • Sun Solaris
  • Pengaturcaraan & Pembangunan
    • Pengaturcaraan
    • .NET, VB.net, C#.net, ASP.net
    • C, C++
    • Java
    • Ruby, Python, Lua, Perl, CGI, Delphi, Pascal
    • Pengkalan Data
    • Pembangunan Perisian
    • Pembangunan Web
    • Pembangunan Permainan
  • Perisian
    • Pejabat & Internet
    • Multimedia
    • Utiliti & Sekuriti
    • Perisian Sumber Terbuka
  • Perkakasan
    • Sistem
    • Komputer mudah alih
    • CPU, Motherboard & Memory
    • Unit Pemprosesan Pusat
    • Papan Induk
    • Kad Grafik
    • Storan
    • Ingatan Capaian Rawak
    • Aksesori
    • Gajet
  • Rangkaian
    • Rangkaian Komputer
    • Internet
    • Wireless
    • Satellite Broadband
  • Permainan & Hiburan
    • Arcade
    • Permainan PC
    • Permainan konsol
    • Muzik, Movie & Majalah
  • Ekonomi & Kerjaya
    • Bisnes
    • Kerjaya
    • e-income
  • Pendidikan
    • Sumber maklumat
    • Teknologi
    • Pensijilan
    • Sudut Pelajar
  • Bazar
    • Jual & Beli
    • Jual & Beli Pukal
    • Servis & Perkhidmatan
  • Komuniti
    • Sembang
    • Aktiviti
    • Automotif
    • Serious Discussion
    • Hobbies & Living
    • English Corner
    • Ladies Corner
    • Kesihatan
    • Agama

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


AIM


MSN


Website URL


ICQ


Yahoo


Jabber


Skype


Location


Interests


Nama lain

Found 1 result

  1. salam,   mcm ne kalu nk export gridview ke pdf file?sy telh cuba koding spt dibwh ni tp sy dpt error bila run. mcm ne nk solve mslh ni?   harap ada yg boleh membntu..Trima kasih :)      protected void btnExportPDF_Click(object sender, EventArgs e)         {             Response.ContentType = "application/pdf";             Response.AddHeader("content-disposition", "attachment;filename=UserDetails.pdf");             Response.Cache.SetCacheability(HttpCacheability.NoCache);             StringWriter sw = new StringWriter();             HtmlTextWriter hw = new HtmlTextWriter(sw);             //DataList1.AllowPaging = false;             DataList1.DataBind();             DataList1.RenderControl(hw);             //DataList1.HeaderRow.Style.Add("width", "15%");             //DataList1.HeaderRow.Style.Add("font-size", "10px");             DataList1.Style.Add("text-decoration", "none");             DataList1.Style.Add("font-family", "Arial, Helvetica, sans-serif;");             DataList1.Style.Add("font-size", "8px");             StringReader sr = new StringReader(sw.ToString());             Document pdfDoc = new Document(PageSize.A2, 7f, 7f, 7f, 0f);             HTMLWorker htmlparser = new HTMLWorker(pdfDoc);             PdfWriter.GetInstance(pdfDoc, Response.OutputStream);             pdfDoc.Open();             htmlparser.Parse(sr);             pdfDoc.Close();             Response.Write(pdfDoc);             Response.End();         }     error yg keluar : The document has no pages. Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. Exception Details: System.IO.IOException: The document has no pages. Source Error: Line 208: pdfDoc.Open(); Line 209: htmlparser.Parse(sr); Line 210: pdfDoc.Close(); Line 211: Response.Write(pdfDoc); Line 212: Response.End();  
×
×
  • Create New...