- add user user-definable date parameter

Exploration / Indicators
(AmiBroker 4.60)

SYNTAX ParamDate( ''Name'', ''Default date'', format = 0 );
FUNCTION Adds a new user-definable date parameter, which will be accessible via Parameters dialog :
right click over chart pane and select "Parameters" or press Ctrl+R allows to change chart parameters - changes are reflected immediatelly.

  • "name" - defines parameter name that will be displayed in the parameters dialog
  • "default date" - is a string holding date in any any format: YYYY-MM-DD, MM/DD/YY, DD-MM-YY, etc, etc.
  • format - defines return value format, allowable values are:
    0 - return value is a NUMBER and holds DateNum. Ie: 990503 for May 3, 1999,
    1 - return value is a STRING formatted holding date according to your windows regional settings
    2 - return value is a NUMBER and holds DateTime. (new in 6.20)

WARNING: default parameter has to be CONSTANT. This is because these values are cached and are not re-read during subsequent formula evaluations.

IMPORTANT: Parameter names and values must NOT contain non-printable characters (ASCII codes < 32).

EXAMPLE start = ParamDate( "Start Date", "2003-05-03" );
SEE ALSO PARAM() function , PARAMCOLOR() function , PARAMSTR() function , ParamTime() function


The ParamDate function is used in the following formulas in AFL on-line library:

More information:

See updated/extended version on-line.