print variables into FT

Examples step by step how to make your own automated strategy or user indicator
Message
Author
omarloren
Posts: 5
Joined: Wed Nov 23, 2011 1:08 pm

print variables into FT

#1 Postby omarloren » Wed Nov 23, 2011 1:15 pm

Hi I'm starting with FT, I have a little doubt how can I print variables into the FT, I know there is a "Print" function but it only support char *, and I need to print out other types of variables also since I come from metatrader development I need someting like the mql 's "Comment" function, is there any like this.

FT Support
Posts: 905
Joined: Sat Jul 11, 2009 10:54 am

#2 Postby FT Support » Wed Nov 23, 2011 3:11 pm

Hello,

Please convert other variables types to char* i'm not C++ programmer so cannot advise how exactly you can do that but for example in Delphi you can use "IntToStr" and "FloatToStr" functions.
Check our other product here:
http://www.forexcopier.com

FT Support
Posts: 905
Joined: Sat Jul 11, 2009 10:54 am

#3 Postby FT Support » Mon Jul 02, 2012 6:01 am

Please use "sprintf" method, for example

Code: Select all

char buff[30];
sprintf(buff,"ATR = %f",ATR[index+1]);
Print(buff);
Check our other product here:
http://www.forexcopier.com


Return to “Programming lessons”

Who is online

Users browsing this forum: No registered users and 14 guests