Author Topic: IF statement within Amount field when settiing user variable  (Read 1593 times)

Tags:
  • All members
  • Posts: 149
Can someone please clear this up...

I'm trying to set a user variable to count number of bets placed called 'BetsPlaced' and if a bet has been placed check for it in value field using following formula and add to the 'BetsPlaced' variable...

IF(bm_backa>0, BetsPlaced+1, BetsPlaced+0)

Why wont the variable be to set to 1,or add to it, when a bet has been placed and when I display User variables, the bm_backa is greater than 0 so that is OK.

Can anybody help please.
Regards
Harry

  • All members
  • Posts: 149
Hi,
You can see in the picture I've attached that a £2 bet has been placed on 'Outrage' and bm_backa is showing £2 but my variable(BetsPlaced) had not been updated to count number of bets placed!
Regards
Harry

  • Moderator
  • Posts: 3597
*
Hi
Your formula contains circular references, after 1 bet the result looks like this:
IF(4.00>0,IF(4.00>0,BetsPlaced+1,BetsPlaced+0)+1,IF(4.00>0,BetsPlaced+1,BetsPlaced+0)+0)

It would be better to simply update a counter: Value: BetsPlaced+1
and use conditions to fire the trigger, e.g. selections back matched is greater than 0

however, there are bet counter variables built in to the program you might find easier:
General variables, allbets_....loads of them
Market variables, market_mbnum etc...
Selections variables, bm_number, bm_backnum, bm_laynum etc...
 
Please read the following disclaimer with regards to the information you may request and obtain on our forum. This specifically concerns trigger files and various instructions as to how to implement a strategy.

  • All members
  • Posts: 149
ok thank you

 

Please note, BetFair is seems to be currently OFFLINE