{{Quickfixn}} How to place a Stop loss and Take Profit in New Order Single

Pavel pavka1799 at gmail.com
Tue Jul 31 08:12:01 PDT 2018


Hi Javier

Answer to your question depends mostly on your exchange; QuickFix is a
library to construct/parse FIX messages, and each exchange has its own
specifics of messages.
Generally it should be something like the below:
QuickFix.FIX44.NewOrderSingle newOrderSingle = new
QuickFix.FIX44.NewOrderSingle(
                new ClOrdID(<your order ID>),
                new Symbol(<traded symbol>),
                new Side(<buy or sell>),
                new TransactTime(<...>),
                new OrdType(<e.g. OrdType.Market - see spec of your
exchange>);
newOrderSingle.Set(new Currency(<your currency>));
newOrderSingle.Set(new OrderQty(<order quantity>));
newOrderSingle.Set(new Price(<...>)); // usually not needed for Market
...

Once again, the above is just an example (for FIX4.4), which you need to
adjust to construct a message satisfying your particular exchange's message
specification.
So I guess if you follow the Exchange's documentation on how to fill the
fields in the message, it should work.

Regards,
Pavel


On 31 July 2018 at 16:34, Javier Hertfelder <javier at fxstreet.com> wrote:

> Hi guys,
>
> We are kind of new in FIX and we are struggling with a very simple action,
> place an Market Order with an Stop loss and Take Profit.
>
> Any suggestions?
>
>
> Javier Hertfelder, CTO | www.fxstreet.com |
>
> Tel. +34 93 3040495
>
> Gtalk: javier <http://goog_2145176996>@fxstreet.com <javier at fxstreet.com>
>  - Stay connected <http://about.fxstreet.com/stay-connected-social-media/>
>
>
>
> _______________________________________________
> Quickfixn mailing list
> Quickfixn at lists.quickfixn.com
> http://lists.quickfixn.com/listinfo.cgi/quickfixn-quickfixn.com
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.quickfixn.com/pipermail/quickfixn-quickfixn.com/attachments/20180731/52e429e5/attachment.htm>


More information about the Quickfixn mailing list