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

[amibroker] AFL Date-Time Question



PureBytes Links

Trading Reference Links

Hello,

I have a question regarding date-time functions for a specific bar. 

How do I find the day / month / year for the specified bar ? The Month(), Year(), Day() functions do not take parameters.

For example, in this sample code I want to do specific operations if the month is January ...

Any trick ?

// ---- SAMPLE CODE BEGIN ------------

for( iBar = 0; iBar < BarCount ; ++iBar )
{
    // Here do something if the month is January ....
    if( MONTH_OF_THIS_BAR == 1 )
    {
        // Do something ..
    }  
}

// ---- SAMPLE CODE END ---------------

Thanks in advance,
Adheer Pai.
Content-Description: "AVG certification"
No virus found in this incoming message.
Checked by AVG Free Edition.
Version: 7.5.430 / Virus Database: 268.15.6/566 - Release Date: 12/3/2006 4:36 PM