Skip to main content


Command Description

Extracts text from the specified pages of a PDF file

Command Prototype

sRet = PDF.GetPageText(filePath,password,pageStart,pageEnd)

Parameter Description

filePathTruepath'''C:\Users'''Path of the PDF file
passwordTruestring""PDF file password. No need to fill in if no password
pageStartTruenumber1The starting page number of the text (starting from 1)
pageEndTruenumber2The ending page number of the text


sRet,The variable used to save the output of the command.


/************************************Get the specified page text************ ********************* 
Command prototype:
sRet = PDF.GetPageText ('' 'C: \ Users' '', "", 1,2)
Input parameters:
filePath--PDF file path
password--PDF file password, no password need to fill in
pageStart--Get the starting page number of the text, starting from 1
pageEnd--get the end page number of the text
Outgoing parameters:
sRet--the result after the command is run
Dim filePath='''C:\Users\Chance\Desktop\testPDF\Laiye Technology RPA Product Introduction.pdf'''
Dim password=""
Dim startPage=1
Dim endPage=2
sRet = PDF.GetPageText (filePath, password, startPage, endPage)
TracePrint (sRet)