Introduction

APGetInfo is a command-line application. If you are used to the Microsoft Windows or Apple Mac OS X operating system, you may not be familiar with running command-line tools. This section shows you all you need to get started.

  • Windows tells you how to use APGetInfo on Windows.
  • Mac OS X tells you how to use APGetInfo on Macintosh.

Note: You can refer to the Getting Started With Command Line Applications for additional information on using command-line applications.

Windows

To run APGetInfo in Windows, you need to open a Command Prompt window.

In Windows XP, Vista or 7:

  • Click Start > Programs > Accessories > Command Prompt

The Command Prompt window opens.

Some basic commands

At the command prompt, you type each command, and press the Enter key to execute it. You can use the mouse to select text to copy or cut to the clipboard, but you cannot position the cursor with it. The command line is completely keyboard driven. Navigation keys are shown below:

Key Action
Backspace Delete previous character
Right arrow Move right one character
Left arrow Move left one character
Up arrow Recall previous command
Tab File or directory name auto complete
Enter Execute command

In addition to running programs, you have many commands to navigate and maintain the system. Two important ones are cd and dir.

Changing directories

Use the cd command to change directories. For example, to change to the directory that APGetInfo is located in, type:

C:\>cd \Appligent\APGetInfo\

The command prompt changes to:

C:\Appligent\APGetInfo>

to show you where you are.

To move back one level, use the shortcut of two periods (..)

C:\Appligent\APGetInfo>cd..

Don’t forget to press the Enter key after every command. You will now be in this directory:

C:\Appligent>

Move back to APGetInfo:

C:\Appligent>cd APGetInfo

Listing the contents of a directory

Use the dir command to list the contents of a directory:

C:\Appligent\APGetInfo>dir

The computer responds with a listing of all the contents of the APGetInfo directory.

If the directory contents fly by too fast to read, do this:

C:\Appligent\APGetInfo>dir /p

The /p switch tells DOS to display one page at a time. Press the Enter key to see the next page.

To see the contents of all the subdirectories at the same time, type:

C:\Appligent\APGetInfo>dir /s

This displays the contents of APGetInfo and all the subdirectories under it.

Running APGetInfo

To run APGetInfo, type the commands on the command line as shown in other sections of this manual and press Enter. For example:

$apgetinfo -o \files\output.txt [options] samples\input.pdf

In this example, the dollar sign stands for the command prompt, a convention used throughout this manual. The command processes the input.pdf file using the options you provide, and then saves the results to output.txt. Note that the relative path is included in the file specifications, so that APGetInfo knows where to find the files. However, the safest way to specify files is to use the full path:

$apgetinfo -o c:\Appligent\APGetInfo\files\output.txt [options] c:\Appligent\APGetInfo\samples\input.pdf

If you do not specify the correct path, you will get a “file not found” error.

Note: Each command must be typed on one line, even if it is presented on more than one line in the manual to fit on the page.

Now, refer to the rest of this User Guide for details about using APGetInfo.

Mac OS X

To run APGetInfo on the Macintosh, you need to open a terminal window. In the Applications folder:

1. Open the Utilities folder.

2. Double-click the Terminal application

The Terminal window opens.

Some basic commands

At the command prompt, you type each command, and press the Return key to execute it. You can use the mouse to select text to copy or cut to the clipboard, but you cannot position the cursor with it. The command line is completely keyboard driven. Navigation keys are shown below:

Key Action
Backspace Delete previous character
Right arrow Move right one character
Left arrow Move left one character
Up arrow Recall previous command
Tab File or directory name auto complete
Return Execute command

In addition to running programs, you have many commands to navigate and maintain the system. Two important ones are cd and ls.

Changing directories

Use the cd command to change directories. For example, to change to the directory that APGetInfo is located in, type:

[yourcomputer:~]user% cd /Applications/Appligent/APGetInfo

The command prompt changes to:

[yourcomputer:Applications/Appligent/APGetInfo]user%

to show you where you are. yourcomputer is the name of your computer, and user is your user name.

To move back one level, use the shortcut of two periods (..)

[yourcomputer:Applications/Appligent/APGetInfo]user% cd ..

Don’t forget to press the Return key after every command. You will now be in this directory:

[yourcomputer:Applications/Appligent]user%

Move back to APGetInfo:

[yourcomputer:Applications/Appligent]user% cd APGetInfo

Listing the contents of a directory

Use the ls command to list the contents of a directory:

[yourcomputer:Applications/Appligent/APGetInfo]user% ls

The computer responds with a listing of all the contents of the APGetInfo directory.

To see the contents of all the subdirectories at the same time, type:

[yourcomputer:Applications/Appligent/APGetInfo]user% ls -R

The -R switch displays the contents of APGetInfo and all the subdirectories under it. Note that these switches are case sensitive. You must use a capital ‘R.’

Running APGetInfo

To run APGetInfo, type the commands on the command line as shown in other sections of this manual and press Return. For example:

$./apgetinfo -o ./files/output.txt [options] ./samples/input.pdf

In this example, the dollar sign stands for the command prompt, a convention used throughout this manual. The ./ tells the computer that the command is in the current directory. The command processes the input.pdf file using the options you provide, and then saves the results to output.txt. Note that the relative path is included in the file specifications, so that APGetInfo knows where to find the files. However, the safest way to specify files is to use the full path:

$./apgetinfo -o /Applications/Appligent/APGetInfo/files/output.txt [options] /Applications/Appligent/APGetInfo/samples/input.pdf

If you do not specify the correct path, you will get a “file not found” error.

Note: Each command must be typed on one line, even if it is presented on more than one line in the manual to fit on the page.

Now, refer to the rest of this User Guide for details about using APGetInfo.