These sample source codes on this page below are displaying how to create new pdf document with pdf sdk in VB.NET. ByteScout Premium Suite can create new pdf document with pdf sdk. It can be applied from VB.NET. ByteScout Premium Suite is the set that includes 12 SDK products from ByteScout including tools and components for PDF, barcodes, spreadsheets, screen video recording.
Want to save time? You will save a lot of time on writing and testing code as you may just take the VB.NET code from ByteScout Premium Suite for create new pdf document with pdf sdk below and use it in your application. This VB.NET sample code is all you need for your app. Just copy and paste the code, add references (if needs to) and you are all set! Enjoy writing a code with ready-to-use sample VB.NET codes.
ByteScout provides the free trial version of ByteScout Premium Suite along with the documentation and source code samples.
Imports Bytescout.PDF ''' <summary> ''' This example demonstrates how to create a document and save it to file. ''' </summary> Class Program Shared Sub Main() ' Create new document Dim pdfDocument = New Document() pdfDocument.RegistrationName = "demo" pdfDocument.RegistrationKey = "demo" ' Add page Dim page = New Page(PaperFormat.A4) pdfDocument.Pages.Add(page) ' Add sample content Dim font = New Font(StandardFonts.Times, 24) Dim brush = New SolidBrush() page.Canvas.DrawString("Hello world!", font, brush, 20, 20) ' Save document to file pdfDocument.Save("result.pdf") ' Cleanup pdfDocument.Dispose() ' Open document in default PDF viewer app Process.Start("result.pdf") End Sub End Class