Click here to Skip to main content
15,920,005 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi friends,

I want help to convert a row in the database into pdf and send that pdf into email address which is in that row.
Posted
Updated 14-Oct-10 21:37pm
v3
Comments
Sandeep Mewara 15-Oct-10 3:35am    
What effort have you made?
Dalek Dave 15-Oct-10 3:37am    
Minor Edit for Grammar.

You can make a html file from the database row then you can convert the html file to the pdf by PdfConverter(wnvhtmlconvert.dll)

using Winnovative.WnvHtmlConvert;

public void Convert()
        {
            PdfConverter pdfConverter = new PdfConverter();
            pdfConverter.LicenseKey = "your license key";
            pdfConverter.PdfDocumentOptions.EmbedFonts = false;
            pdfConverter.PdfDocumentOptions.ShowFooter = false;
            pdfConverter.PdfDocumentOptions.ShowHeader = false;
            pdfConverter.PdfDocumentOptions.GenerateSelectablePdf = true;
            pdfConverter.SavePdfFromHtmlFileToFile("1.html", "1.pdf");
        }


Then you can attach the pdf with the mail. For this you can see this links->

Click

Click

Click
 
Share this answer
 
Your scenario is not quite clear but one of the feasible ways to achieve it could be:
1. Use Windows service that will pick the desired row
2. Create a PDF based on the values
3. Emails the PDF

Now, all the 3 steps are quite long and you need to move step by step. You will find separate articles on all the 3 steps here at code project itself.

Try!
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900