TargetSubId must be assigned

Created at 05 Dec 2016, 00:30
How’s your experience with the cTrader Platform?
Your feedback is crucial to cTrader's development. Please take a few seconds to share your opinion and help us improve your trading experience. Thanks!
olddirtypipster's avatar

olddirtypipster

Joined 18.04.2014

TargetSubId must be assigned
05 Dec 2016, 00:30


I was previously able to connect and logon successfully, but now this happens:

8=FIX.4.4|9=111|35=A|49=*****|56=cServer|34=1|52=20161204-22:27:34|50=Quote|98=0|141=Y|553=*****|554=*****|108=30|10=125|

8=FIX.4.4|9=104|35=5|34=1|49=cServer|52=20161204-22:27:46.527|56=*****|57=Quote|58=TargetSubID must be assigned|10=123|

Has anything changed server side?

 


@olddirtypipster
Replies

cyfer
05 Dec 2016, 02:15

I was not able to conect till I responded to the server the way it did 

I had no successful Logons before forcing that field .. So ..you will have 2 tags with the Value of "Quote"  

Fix Raw

57=Quote

 

if you QuickFix and you're making the Dicitionary dynamically , Pass that tag in the Logon Message

QuickFix

 public void ToAdmin(QuickFix.Message msg, SessionID sessionID)
        {
            if (msg.ToString().Contains("35=A")) //use Message Cracker instead of this
            {      
               msg.SetField(new QuickFix.Fields.TargetSubID("Quote"));
               msg.SetField(new QuickFix.Fields.Username("*******"));
               msg.SetField(new QuickFix.Fields.Password("****"));
            }
        }

 


@cyfer

#EOL
27 Dec 2016, 19:16

if (msg.ToString().Contains("35=A")) //use Message Cracker instead of this
           {      
              msg.SetField(new QuickFix.Fields.TargetSubID("Quote"));
...
           }      

 

i'm not sure if it will work, since TargetSubID is a part of standard header and should be set in every message


@#EOL