[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[amibroker] Date of a previous Buy() signal



PureBytes Links

Trading Reference Links

Hi,

I am trying to format the date of a previous Buy signal to a string:

a = "";

for (i=1; i<BarCount; i++)
{

if (Sell[i]==1)
{	
a = a + DateTimeToStr(ValueWhen(Buy,DateTime()));
}

}

However, the "a = a+..." line does not work. I get "Error 
5....Incorrect type".

Can anyone advise?

Oh - I need the loop to stay intact (ie. the "if (Sell[i]==1)..." 
code), as I have other processing code in this loop.

Thanks.


Content-Description: "AVG certification"
No virus found in this incoming message.
Checked by AVG Free Edition.
Version: 7.5.441 / Virus Database: 268.18.3/693 - Release Date: 2/19/2007 5:01 PM