Alex Gordon
Alex Gordon

Reputation: 60861

how to generate a pdf file with VB.net?

i would like to generate a very simple report with some images and text and i am wondering if there is a way to generate a pdf file with vb.net?

Upvotes: 2

Views: 33771

Answers (5)

Jerry Coder
Jerry Coder

Reputation: 21

Word can export as pdf:

    Dim doc As Word.Document = New Word.Document()
    doc.Content.Text = "Hello World"
    doc.ExportAsFixedFormat("C:\mypath\myfilename.pdf", Word.WdExportFormat.wdExportFormatPDF)
    doc.Close(False)

Upvotes: 2

Perpetualcoder
Perpetualcoder

Reputation: 13591

take a look at this SO question. It pertains to C# but since the libraries are .net compat..you should be ok

UPDATE http://sourceforge.net/projects/pdfsharp/ and http://www.pdf-technologies.com/

Upvotes: 1

JYelton
JYelton

Reputation: 36536

The PDFSharp library (http://pdfsharp.com/) is something I used recently in a C# project. There are a lot of advanced features but fortunately you can start with just a few basic commands. Give it a try.

Upvotes: 2

Matt Hamsmith
Matt Hamsmith

Reputation: 4036

You can export to a PDF file using a Crystal Reports object, which comes packaged with Visual Studio.

Upvotes: 2

Yves
Yves

Reputation: 12507

Use MicrosoftReportViewer from the Toolbox.

Upvotes: 1

Related Questions