Re: [Quickfix-users] Checking for tags in message.
Brought to you by:
orenmnero
From: Tom H. <to...@go...> - 2010-02-25 15:04:16
|
Use if (message.IsSetField(FIX::FIELDS::TransactTime) time = message.getField(FIX::FIELDS::TransactTime); for example Tom Tom Higgins Group CEO Gold-i Ltd & Gold-i LLC MetaQuotes UK & US Mob: +44 (0)7770 950038 Dir: +44 (0)1483 685412 Tel: +44 (0)1483 685410 www.gold-i.com to...@go... Surrey Technology Centre 40 Occam Road Guildford Surrey GU2 7YG Exclusive UK and US Distributor for MetaTrader and TeamWox Finalist for Toast of Surrey Business Awards 2010 NOTICE TO RECIPIENT The information in this email and any attachments may contain confidential and/or privileged information. It is intended solely for the addressee(s). If you are not the intended addressee, please notify the sender immediately (and destroy this email and any attachments from all computers). Any review, copying, redistribution in whole or in parts of this email or its attachments or any other action in reliance to this email or its attachments is strictly prohibited. Email transmission security and error-free status cannot be guaranteed as information could be intercepted, corrupted, destroyed, delayed, incomplete or contain viruses. The sender therefore does not accept any liability for any errors or omissions in the contents of this email or its attachments which may arise as a result of email transmission. -----Original Message----- From: gtsafas [mailto:gt...@rb...] Sent: 25 February 2010 2:10 PM To: qui...@li... Subject: [Quickfix-users] Checking for tags in message. QuickFIX Documentation: http://www.quickfixengine.org/quickfix/doc/html/index.html QuickFIX Support: http://www.quickfixengine.org/services.html I am currently catching execution reports using quickfix in c++. When I look for something like tag 60 (TransactTime) if a message doesnt contain it it rejects it. NYSE for example will not put 60 on some of their messages. How can I check if the tag exists before I set it. FIX::TransactTime fTRANSACTTIME; FIX::Symbol fSYMBOL; FIX::Side fSIDE; FIX::OrderQty fORDERQTY; FIX::LastShares fLASTSHARES; FIX::LastMkt fLASTMKT; FIX::LastPx fLASTPX; FIX::ExecBroker fEXECBROKER; FIX::OrdStatus fORDSTATUS; FIX::ClOrdID fCLORDID; std::cout << std::endl << "Execution Report: " << message << std::endl << std::endl; std::cout << "Transact Time(60): " << message.get(fTRANSACTTIME) << std::endl; std::cout << "Exec Broker(76): " << message.get(fEXECBROKER) << std::endl; std::cout << "Symbol(55): " << message.get(fSYMBOL) << std::endl; std::cout << "Side(54): " << message.get(fSIDE) << std::endl; std::cout << "FULL Order Quantity(32): " << message.get(fORDERQTY) << std::endl; std::cout << "Order Quantity(32): " << message.get(fLASTSHARES) << std::endl; std::cout << "Price(31): " << message.get(fLASTPX) << std::endl; std::cout << "Last Market of Execution(30): " << message.get(fLASTMKT) << std::endl; -- View this message in context: http://old.nabble.com/Checking-for-tags-in-message.-tp27714438p27714438.html Sent from the QuickFIX - User mailing list archive at Nabble.com. ------------------------------------------------------------------------------ Download Intel® Parallel Studio Eval Try the new software tools for yourself. Speed compiling, find bugs proactively, and fine-tune applications for parallel performance. See why Intel Parallel Studio got high marks during beta. http://p.sf.net/sfu/intel-sw-dev _______________________________________________ Quickfix-users mailing list Qui...@li... https://lists.sourceforge.net/lists/listinfo/quickfix-users |