How to cancel all unmatched orders on the market/selection by bot?


I need some help.

Heh... It looks like an easy task but I can't figure out how to do that... I need to cancel all unmatched orders on the market/selection.

Also, I've got another question. How to place orders at all selections in the market at once? For example, there are 25 selections(Horse Race) and I want to lay at 1.1 on every selection. I see there's a bot named "Place Bet" but it can only place bets on specific selection so does it mean that I need to make 25 bots for that task?

It would be nice if there was an option that I can tick and make the bot to place the order at all selections at the market.

Any help would be appreciated.


Updated by Stefan:

Here is the video preview of your bot trigger. It offers two parameters LayOdds and LayStake, by default are set to 10.0 @ 1.1 The offset bet as you call it, in bfexplorer terminology Hedge bet is managed by action bot entered by parameter BotName. This approach allows to setup different types of bots for closing a bet position on a selection.

It was not required but depending on the lay odds you enter it could happen that at one moment can be matched lay bets on more than one selection; the bot trigger manages such situations as well.

Download “Horse Racing Trade First Favourite Bot Trigger” script if you want to test it or build your own script from it.

Comments ( 89 )

  • Stefan
    21.9.2015 19:46:01

    Ilya, we already know that you are able to search for files in your computer. The question is, are you familiar with Open File dialog? I believe as a lover of Advanced Cymatic Trader or Betting Assistant you know how to work with Excel, and Excel offers Open File dialog as well, am I right?

    Bfexplorer is maybe not so good as above mentioned betfair apps but in user interface design bfexplorer supports common UI design partners, like Open File dialog.

    I already mentioned that Execute trigger bot offers two options for entering trigger file, a bot source code, with the file extension .fs, or .fsx, and bot trigger assembly file with the file extension .dll. By default you are offered to open Script files, but you can click on the combo box (above Open button) and there you can find the second option: Bot trigger assemblies, please use this option.

    I will help you and others and in the latest version I am about to release I will set by default the Bot trigger assemblies option, as frankly to say I maybe the only one who will use the other option: Script files.

  • Ilya Nikol
    21.9.2015 19:58:40

    Stefan, I tried to run BackCorrectScore00LayDrawTrigger.dll and it worked just fine!

  • Ilya Nikol
    21.9.2015 20:00:30

    P.S. Unfortunately, I am not familiar with Open File dialog.

  • Stefan
    21.9.2015 20:26:45

    Yes Ilya, I believe you, after yesterday’s lecture about vital features which every trader use, I simply learn everyday something new, thank you once again.


    Never mind that Open File dialog actually exists in every app which opens some files, as the Open File dialog is actually part of base user interface of Windows operating system, so in every app it looks exactly the same way.


    As I said I learn everyday something new.

  • Ilya Nikol
    21.9.2015 21:31:27


    Heh : - ) Stefan, when I talked about the vital features I didn't want to lecture anyone and I didn't mean that other trading platforms such as Bet Angel, Cymatic Trader or Geek Toys have such features and BFexplorer don't.


    I have more than 10 years trading experience and I also trade the equity market and forex market. About 10 ago years I stared with equity market and forex market and only recently started to trade on Betfair. During that period I've tried about 200 different platforms some of them had more features and some of them less but all of them had "Tick Offset", "Stop Loss", "Trailing stop", "Fill or Kill", "Place Market Order", "Place Limit Order" because these features are vital for trading and it doesn't matter at what market do you trade.


    Now I see that it's possible to have all that features in BFexplorer and even better!


    Also It needs to be said that some functional is missing in BFexplorer and it can be improved further to be the best platform for Betfair! : - )  For example, I can’t automate my strategy right now but it’s very simple one.



    Back on the topic: Stefan, where I can take the file that I showed on the video? HorseRacingTradeFavoriteFirst.dll?  


  • Ilya Nikol
    21.9.2015 22:10:42


    Heh... of course I know what is "Open File Dialog" I just didn't get it when you asked about it because as you can see my English isn't so good : - )


    When I tried to open the file I saw that it opens only *.fs and *.fsx so it made me think that I should to the other *.dll into some specific directory.


    I'm also isn't programmer and  I have only average PC skill : -)


  • Stefan
    21.9.2015 22:21:12

    I have got some problems to build the latest release after Microsoft pushed some updates to VS and now I am not able to build my solution.

    I see you have got bigger experiences than me in every aspect. Meantime the latest version will be released, may I ask you to choose one of the points you mentioned and explain us what you actually mean?

    I think it will be interested to learn from such an expert as you. For instance I had no idea what you mean by tick offset, I must search on Cymatic forum what does it actually mean, but am not sure if I understand it.

  • Ilya Nikol
    21.9.2015 23:08:10


    It can be called whatever you want and I just call it "Tick Offset" because I saw it called liked that in many trading platforms for Belfair.  In other trading platforms for equities, futures, forex market such order is called "Take Profit" : - )


    Every trader needs this functional and it doesn't matter where you trade equities, futures, forex or betfair :


    1) You place order at the specific price and amount.


    2) When your order is matches then opposite order should be placed with specific price and amount.


    3) You should be able to set the specific price and amount for the initial and the offseting order.


    4) Also it would be nice to have an ability to add some options to the initial and the offset order such as "Keep In Play or Not", "Fill or Kill" and how to handle partial fills, for example, should be it offset or need to wait for full match.


    Always there's an option to attach also the “Stop Loss” the order.


    For example, you creates an order to Back $ 10 at price 3.0 and attaching "Tick Offset/Profit Take" and "Stop Loss" to it.


    In equites, forex platforms such thing can be done in few clicks and even by someone without any PC skill : -) Everybody get used to that all platforms have such functional and nobody think it something special and if you don’t find it the platform than you think wtf? : - )

    Such functional shouldn't be hidden somewhere in deep in the interface and it should be place at most visible place and even the dummies should be able to easily find it and use it because it's like pedals and wheels in the car. : - )





  • Stefan
    21.9.2015 23:36:59

    And what about "Place Market Order", "Place Limit Order", what does it mean?


    I never heard about "Place Market Order".  "Place Limit Order", in what is such bet/order limited, can we actually profit from such bet if it is limited in any way?

    Well yes, tick offset, it is just different terminology therefore what makes you think that bfexplorer actually missing anything from what you said about tick offset. I said that I do not think bfexplorer is good app, such Cymatic or Betting Assistant those are true masterpieces in software application development, not even telling about Geektoy or Bet Angel those are the best app on betfair market, at least everyone say so.

    Well, first time I met you on forum for betfair developers and you say you are not a programmer, you must be a true expert if you were able to understand what geeks there are talking about. I have got problems here to explain anything about programming to common people, I mean to non programmers.

  • Ilya Nikol
    22.9.2015 0:42:19


    "Marked Order" can be used only in the equity trading so just ignore that I mentioned it and "Limit Order" is just a regular Betfair order. My apologies for any confusion I just have got used to that there are always 2 type of orders in the equity trading. : - ) Heh... Maybe at some point in the future Belfair also starts to support "Market" orders. : - )


    I tested Cymatic, Geektoy, Bet Angel and some other and didn't see anything special they all are average at least compare to any platform for equity trading, they all try to bring the same trading functional as the equity trading platforms offers but I have impression that there’s lack of understanding what average trader need. There are many stuff that is kinda useless and lack of really important features.


    I see that BFexplorer can be easily improved to become much better than all those platforms and it has better potential.


    I suggest you improve some essential functional and make it more "visible" for the users and more easily to configure.


    The trading starts from the point when trader place an order and attaches "Take Profit"/ "Stop Loss/Trailing Stop loss" to it and you shoudl be able to cancel that order in one click and all that should be done in few clicks and the trader shouldn't think where to find such functional it should be very visible and easy to configure and it shoud be the first thing you see when log in to the platfrom. You just can't trade without it and if the trader struggles to find or struggles to configure it then he just walk away, especially, the trader who also traders on other markets such as equity because he is "spoiled" with functional that the platforms for equities trading offers to the traders. : - )

    When the essential functional is present then you go to more complex stuff such as bots and automated trading.  

    P.S. Stefan, I came to that forum by mistake and I’m not a programmer.