ByteScout PDF Suite - VBScript - Extract image coordinates by page from pdf with pdf extractor sdk - ByteScout

ByteScout PDF Suite – VBScript – Extract image coordinates by page from pdf with pdf extractor sdk

  • Home
  • /
  • Articles
  • /
  • ByteScout PDF Suite – VBScript – Extract image coordinates by page from pdf with pdf extractor sdk

How to extract image coordinates by page from pdf with pdf extractor sdk in VBScript with ByteScout PDF Suite

Learn to extract image coordinates by page from pdf with pdf extractor sdk in VBScript

The sample source codes on this page shows how to extract image coordinates by page from pdf with pdf extractor sdk in VBScript. What is ByteScout PDF Suite? It is the bundle that provides six different SDK libraries to work with PDF from generating rich PDF reports to extracting data from PDF documents and converting them to HTML. This bundle includes PDF (Generator) SDK, PDF Renderer SDK, PDF Extractor SDK, PDF to HTML SDK, PDF Viewer SDK and PDF Generator SDK for Javascript. It can help you to extract image coordinates by page from pdf with pdf extractor sdk in your VBScript application.

This prolific sample source code in VBScript for ByteScout PDF Suite contains various functions and other necessary options you should do calling the API to extract image coordinates by page from pdf with pdf extractor sdk. This VBScript 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! Want to see how it works with your data then code testing will allow the function to be tested and work properly.

The trial version of ByteScout PDF Suite can be downloaded for free from our website. It also includes source code samples for VBScript and other programming languages.

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

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

ExtractImagesCoordinatesByPages.vbs
      
' Create Bytescout.PDFExtractor.ImageExtractor object Set extractor = CreateObject("Bytescout.PDFExtractor.ImageExtractor") extractor.RegistrationName = "demo" extractor.RegistrationKey = "demo" ' Load sample PDF document extractor.LoadDocumentFromFile("..\..\sample1.pdf") ' Get page count pageCount = extractor.GetPageCount() ' Extract images from each page For i = 0 To pageCount - 1 j = 0 ' Initialize page images enumeration If extractor.GetFirstPageImage(i) Then Do outputFileName = "page" & i & "image" & j & ".png" ' display coordinates of the image MsgBox "Image #" & CStr(j) & " on page #" & CStr(i) & vbCRLF & "Coordinates: " & _ CStr( extractor.GetCurrentImageRectangle_Left()) & ", " & CStr( extractor.GetCurrentImageRectangle_Top()) & ", " & _ CStr( extractor.GetCurrentImageRectangle_Width()) & ", " & CStr( extractor.GetCurrentImageRectangle_Height()) j = j + 1 Loop While extractor.GetNextImage() ' Advance image enumeration End If Next Set extractor = Nothing

ON-PREMISE OFFLINE SDK

60 Day Free Trial or Visit ByteScout PDF Suite Home Page

Explore ByteScout PDF Suite Documentation

Explore Samples

Sign Up for ByteScout PDF 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 PDF Suite Home Page

Explore ByteScout PDF Suite Documentation

Explore Samples

Sign Up for ByteScout PDF Suite Online Training

ON-DEMAND REST WEB API

Get Your API Key

Explore Web API Docs

Explore Web API Samples

Tutorials:

prev
next