You must Sign In to post a response.
  • Category: ASP.NET

    How to retrieve data from database in pdf format

    my table in sql server is employeep
    with columns eid,firstname,lastname,salary
    so in my employee .aspx page i have dropdown named ddlemployeesand button control named btnreport
    so if i selected any value in dropdown and click on btnreport if the value in eid then record related to that value should come from database in pdfformat
  • #761392

    If you are saving pdf bytes in the database you can retrieve it as PDF. But your case, you have to create PDF using C#.

    Normally we will use iTextSharp libraries

    Refer the following link for creating PDF file

    By Nathan
    Direction is important than speed

  • #761396


    If you need pdf convertion to data means

    You can go through this url

    Name : Dotnet Developer-2015
    Email Id

    'Not by might nor by power, but by my Spirit,' says the LORD Almighty.

  • #761415
    As per your requirements, when you selected an record in the dropdown list, you need to retrieve the data into the datatable and then you can use the ExportToPdf method which will take the datatable as the input parameter and then export all your records.
    iTextSharp API can be used to export data to PDF.
    Hope it will be helpful to you.

    Pawan Awasthi(DNS MVM)
    +91 8123489140 (whatsApp), +60 14365 1476(Malaysia)

  • #761459

    If you want to export your database data to pdf then using third party tool you can achieve it by using ITextSharp, you can download latest iTextSharp dll and add reference to your project and then add namespace to the application and then you can easily perform Exporting data into PDF format.

    Refer below link this will helpful to you how to export data into PDF format.

    Give respect to your work, Instead of trying to impress your boss.

    Blog :

Sign In to post your comments