how to get daily profit of the day using AccountEquity()
hello, is this code right? I'm trying to use percentage on my Profit so when the AccountEquity() >= DailyProfitTarget it will close all of the trades I'm not sure on how to code the DailyProfitTarget tnx for the help
double DailyProfitTarget=AccountEquity()+InpDailyProfitInPercentage;
if(AccountEquity>=DailyProfitTarget)
CloseAllTrades(); No, think about it. If your equity is 1000 and daily profit is 100, your target is 1,100
How will 1000 ever be larger than 1,100 ?
My daily profit is on percentage if account equity gain %target percentage it will close all trades
As I said, think about it
double DailyProfitTarget=AccountEquity()+InpDailyProfitInPercentage;
if(AccountEquity>=DailyProfitTarget)
CloseAllTrades(); double DailyProfitTarget= X + Y;
if(X>=X+Y)
CloseAllTrades();
hello, is this code right? I'm trying to use percentage on my Profit so when the AccountEquity() >= DailyProfitTarget it will close all of the trades I'm not sure on how to code the DailyProfitTarget tnx for the help
hello, is this code right? I'm trying to use percentage on my Profit so when the AccountEquity() >= DailyProfitTarget it will close all of the trades I'm not sure on how to code the DailyProfitTarget tnx for the help