How Do I Set Up Conditional Pasting in QAS Pro?

Document type: Tech doc  
Associated product(s): Product name: Pro Version: 4.0 + Implementation: StandaloneOS: Windows
Views: 196  |  Created: 2 years agoLast updated: 2 years ago

Summary

There are a variety of useful commands that can be entered into the configuration tool, when pasting addresses into your database/application. This document outlines some of the conditional pasting options

Solution

In the pasting section of a layout, you can specify keystrokes to be added before and after address lines and before and after the whole address, for example “Enter” so that each address line is on a new line, or “Tab” to navigate between fields when pasting into a database.

Here are the possible options for conditional pasting:

  • {>nkeypress}

This command tells QAS Pro to paste the specified keypress if the line is greater than n characters long.

Example: {>0enter} This tells QAS Pro to paste an Enter key press only if there is something on the line to be pasted. If the line is blank, Enter is not pasted and effectively no line is pasted.

  • {<nkeypress}

This command tells QAS Pro to paste the specified keypress if the line is less than n characters long

Example: {<30tab} This tells QAS Pro to paste a Tab character as long as there are less than 30 characters on the line. This is useful on systems where you automatically tab out of a field when it is filled up. With this setting, you prevent two tabs being pasted at the end of a 30-character line.

  • {!nkeypress}

This command tells QAS Pro to paste the specified keypress only if the line is not equal to n characters long.

Example: {!8enter} This tells QAS Pro not to paste an Enter key press if the line is 8 characters long.

  • {=nkeypress}

This command tells QAS Pro to paste the specified keypress only if the line is exactly equal to n characters long.

Example: {=40enter} This tells QAS Pro not to paste an Enter key press unless the line is 40 characters long.

  • {space-n}{keypress}

This command tells QAS Pro to pad the line out to n characters before pasting the specified keypress. You don't have to choose the space character, but this is the most common padding character.

Example: {space-30}{tab} This tells QAS Pro to pad the line out to 30 characters before pasting a Tab character (to move on to the next field).

  • {waitnmilliseconds}

This command tells QAS Pro to wait a specified number of milliseconds.

Example: {wait2000} This tells QAS Pro to wait 2 seconds before pasting. This is potentially useful with a terminal emulator, enabling the underlying application to 'settle down' before pasting is applied.

NOTE: If there are spaces between any of the keypress elements, the pasting sequence will not perform as described above. You must remove all spaces otherwise the Configuration Editor reads the space and enters the {space} keyword in its place!

Was this document helpful?

What can we do to improve this information?