ByteScout Premium Suite - VBScript - Create drawing template for pdf with pdf sdk - ByteScout

ByteScout Premium Suite – VBScript – Create drawing template for pdf with pdf sdk

  • Home
  • /
  • Articles
  • /
  • ByteScout Premium Suite – VBScript – Create drawing template for pdf with pdf sdk

How to create drawing template for pdf with pdf sdk in VBScript and ByteScout Premium Suite

Learn to create drawing template for pdf with pdf sdk in VBScript

Quickly learn how to create drawing template for pdf with pdf sdk in VBScript with this sample source code. ByteScout Premium Suite: the bundle that includes twelve SDK products from ByteScout including tools and components for PDF, barcodes, spreadsheets, screen video recording. It can create drawing template for pdf with pdf sdk in VBScript.

Want to save time? You will save a lot of time on writing and testing code as you may just take the VBScript code from ByteScout Premium Suite for create drawing template for pdf with pdf sdk below and use it in your application. Simply copy and paste in your VBScript project or application you and then run your app! Use of ByteScout Premium Suite in VBScript is also described in the documentation included along with the product.

Our website gives trial version of ByteScout Premium Suite for free. It also includes documentation and source code samples.

On-demand (REST Web API) version:
 Web API (on-demand version)

On-premise offline SDK for Windows:
 60 Day Free Trial (on-premise)

Templates.vbs
      
' This example demonstrates how to use templates. ' Create Bytescout.PDF.Document object Set pdfDocument = CreateObject("Bytescout.PDF.Document") pdfDocument.RegistrationName = "demo" pdfDocument.RegistrationKey = "demo" Set comHelpers = pdfDocument.ComHelpers ' Prepare simple template (for example, a logo) and draw it on every page: ' Create template of specified size Set template = comHelpers.CreateGraphicsTemplate(250, 50) ' Draw the logo Set lightBlueBrush = comHelpers.CreateSolidBrush(comHelpers.CreateColorRGB(200, 200, 255)) template.DrawRectangle_2 (lightBlueBrush), 0, 0, 250, 50 Set timesFont = comHelpers.CreateStandardFont(comHelpers.STANDARDFONTS_TIMESBOLDITALIC, 24) Set blackBrush = comHelpers.CreateSolidBrush(comHelpers.CreateColorGray(0)) template.DrawString "My Company Logo", (timesFont), (blackBrush), 30, 10 ' Add few pages and draw the prepared template on each one For i = 0 To 2 Set page = comHelpers.CreatePage(comHelpers.PAPERFORMAT_A4) page.Canvas.DrawTemplate (template), 10, 10 pdfDocument.Pages.Add(page) Next ' Save document to file pdfDocument.Save("result.pdf") ' Open document in default PDF viewer app Set shell = CreateObject("WScript.Shell") shell.Run "result.pdf", 1, false

ON-PREMISE OFFLINE SDK

60 Day Free Trial or Visit ByteScout Premium Suite Home Page

Explore ByteScout Premium Suite Documentation

Explore Samples

Sign Up for ByteScout Premium Suite Online Training

ON-DEMAND REST WEB API

Get Your API Key

Explore Web API Docs

Explore Web API Samples

VIDEO

ON-PREMISE OFFLINE SDK

60 Day Free Trial or Visit ByteScout Premium Suite Home Page

Explore ByteScout Premium Suite Documentation

Explore Samples

Sign Up for ByteScout Premium Suite Online Training

ON-DEMAND REST WEB API

Get Your API Key

Explore Web API Docs

Explore Web API Samples

Tutorials:

prev
next