Storing AccountEquity() Value in variable during a certain time that DOESN'T CHANGE - page 2

Ahmet Metin Yilmaz  
Gabriel Bérard # :
Oh, so you're saying that I can find the Account Equity value at the beginning of the day using order history to get the sum of profits for all trades taken during the day. That way I can use my beginning account balance value and the sum of PNL for the day to find where I am at?

I would of found it easier to store the value of AccountEquity() but I guess that will work, thanks a lot!

Good luck with

William Roeder  
Gabriel Bérard #: Cause isn't AccountEquity() a function that if I assign to a variable will continually update instead of storing the accountequity() value at that time?
  1. AccountEquity() is a function. Has nothing to do with your variable. Variables only update when you assign to them.
  2. Assign to your static/global variable at the start of a new day. This is what you started with
    If(Hour() == 0 && Minute() == 0)
       StartingDailyEquity = AccountEquity();