×
Full Guide
Quick Links

Syntax of Bet Rules & Individual commands

 
The syntax of the betting commands in Excel correlates with the global settings parameters used at the top of Bet Angel when placing a bet on the one-click screen. e.g. The are options to specify offsetting, fill or kill, batches etc.
There are also individual commands for bet cancellation, greening, and trade closure.  There are also some advanced commands for controlling Automation via Excel.
 
All commands are entered against the relevant selection in column L. e.g. L9, L11, L13 etc
 
Betting commands
 
BACK
Place a Back bet (price and stake provided by columns M & N)
LAY
Place a Lay bet (price and stake provided by columns M & N)
 
Optional parameters that can be appended to the betting commands
 
OFFSET:x
Apply an offset bet x ticks away
OFFSET_PERC:x.x
Apply an offset bet x.x percent away (rather than using ticks)
FILL_KILL:TRUE/FALSE
When TRUE a fill or kill delay will be applied, the number of seconds being specified by the KILL_DELAY parameter
KILL_DELAY:x
x represents the number of seconds to apply to the fill or kill routine
BATCHES:x
When offsetting, use up to x batches
STOP:x
Apply a stop trigger x ticks away (normally applies to an offset bet unless OPENING_STOP has been used)
STOP_PERC:x.x
Apply a stop trigger x.x percent away (rather than using ticks)
STOP_PLACE:x
When a stop has triggered, place the stop bet x ticks away
STOP_PLACE_PERC:x.x
When a stop has triggered, place the stop bet x.x percent away (rather than using ticks)
TRAILING_STOP:TRUE/FALSE
Specifies whether the stop should be trailing or not
WITH_GREENING:TRUE/FALSE
Specifies whether to offset with greening or not
OPENING_STOP:TRUE/FALSE
When TRUE the stop will be applied to the opening bet rather than the offset
 
Example betting command
 
The following rule will place a lay order in the market; hold it in the market for 60 seconds to wait for it to be filled. If it is not filled it will be cancelled, if it is filled it will apply ‘with greening’ to the offset order one tick above and apply a trailing stop against the order which will exit the position moves three ticks against us.
 
=LAY OFFSET:1 FILL_KILL:TRUE KILL_DELAY:60 STOP:3 TRAILING_STOP:TRUE WITH_GREENING:TRUE
 
Individual commands (columns M & N are not used)
 
CLOSE_TRADE
Close a position using net stake on this selection at the currently available price
GREEN
Close and green a position on this selection by invoking the built-in greening routine within Bet Angel.  Any profit or loss on the selection will be evenly spread across all selections.
CANCEL
Cancels an individual unmatched bet whose Betfair bet reference is held in column R for this selection
CANCEL_ALL
Cancels all bets for the selection
CANCEL_ALL_BACK
Cancels all unmatched back bets for this selection
CANCEL_ALL_LAY
Cancels all unmatched lay bets for this selection
 
 
Advanced commands to link Excel with Advanced Automation
 
SET_NOMINATED1
Sets this selection as the first Nominated selection in Guardian
CLEAR_NOMINATED1
Clears it
SET_NOMINATED2
Sets this selection as the second Nominated selection in Guardian
CLEAR_NOMINATED2
Clears it
SET_AUTO <automation rule name>
Assign an Automation rules file to the market in Guardian
CLEAR_AUTO
Clears the rules file from the market
SET_SV FOR:<SELECTION|MARKET|EVENT> NAME:<name> VALUE:<value>
Assigns a stored value
CLEAR_SV FOR:<SELECTION|MARKET|EVENT> NAME:<name>
Clears a stored value
 
 
Notes:
 
The FOR command is optional and defaults to SELECTION when used in a individual command
 
The commands can be chained together to set multiple values in one go, e.g.
 
SET_SV FOR:SELECTION NAME:Test1 VALUE:42 NAME:Test2 Value:99 NAME:Test3 Value:200
 
or
 
CLEAR_SV FOR:SELECTION NAME:Test1 NAME:Test2 NAME:Test3
 
 
As with all commands, they will be processed when the Status cell in column O is empty and will show OK / ERROR / FAILED when processing is complete.