Macros are certain strings that are either replaced or processed by the program when it inserts lines. Using macros, you can add the current time and date, insert the commands emulating pressing the Tab or Enter keys, etc.

You can add macros into your lines using the main menu of the configuration window String -> Insert Macro or write them manually in the line body.

Supported types of macros

  • %ExTime(...)% - used to insert current date and time in arbitrary format.
  • %Dictionary(...)% - automatic substitution with text from the common or local dictionary when a template is pasted.
  • %Control(...)% - used to emulate control keys, such as TAB, ENTER, CTRL+N and others. Also this macro can be used to make a pause when inserting a line.
  • %Print(..)% - used to insert a line by emulating keypresses instead of using the clipboard.
  • %Clip()%, %Clip(x)% - to paste data from clipboard or clipboard history.
  • %ClipAsPlainText()%, %ClipAsPlainText(x)% - to paste text from clipboard or clipboard history without formatting.
  • %Open(...)% - open documents, web-pages or run other programs.
  • %Remark(...)% - Add comments to complicate macros.
  • %List(...)% and %RandomFromList(...)% Macros for choosing a line from the previously defined list.
  • %RandomNumber(x,y)% - to paste a random number from specified range (x <= number <= y).
  • %Env(...)% - insert value of environment variable.

General information

Note: The %ExTime(...)%, %Dictionary(...)%, %Remark(...)%, %List(...)% and %RandomFromList(...)%, %RandomNumber(x,y)%, %Env(...)% - macros are case-sensitive. The %Control(...)%, %Print(...)%, %Open(...)% and %Clip()% are not case-sensitive.

Hint: Do not separate macros with spaces or newlines only for convenience. These separators will be inserted into the application through the clipboard. For example in the "%Control(ctrl_o)% %Print(file.txt)%" line, after sending the Ctrl+O combination, Flashpaste will copy the " " character (space) in the clipboard and insert it into the clipboard and only after this it will print "file.txt". The correct variant is the following: "%Control(ctrl_o)%%Print(file.txt)%"