s loo / 프로필

s loo
Can you help me correct my coding , in which I'd like to trail both TP and SL, may be I am too optimistic but it seems do not working. please help to correct it : it is a function looks like this following:
////////////////////// trailing profit BOOL function /////////
void TrailingProfit()
{
if profit<=100 useLossToClose=false;
else useLossToClose=true;
if profit>profitToClose
lossToClose=profitToClose;
profitToClose=profitToClose+50;
}
and I put it in the EA like :
int start()
{
TrailingProfit();
....
}
Thank you.
////////////////////// trailing profit BOOL function /////////
void TrailingProfit()
{
if profit<=100 useLossToClose=false;
else useLossToClose=true;
if profit>profitToClose
lossToClose=profitToClose;
profitToClose=profitToClose+50;
}
and I put it in the EA like :
int start()
{
TrailingProfit();
....
}
Thank you.
: