Packagecom.amcharts.stock
Classpublic class PeriodSelector
InheritancePeriodSelector Inheritance mx.core.UIComponent

PeriodSelector class. Displays "from" and "to" date (and time) input fields, also predefined period buttons.



Public Properties
 PropertyDefined by
  endDateField : DateField
DateField of end date.
PeriodSelector
  fromText : String
Text displayed next to "from" date input field.
PeriodSelector
  inputFieldsEnabled : Boolean
Specifies whether period selector displays "from" and "to" date input fields.
PeriodSelector
  limitToAvailableDates : Boolean
If true, the period selector calendars won't allow selecting dates which are out of data providers range.
PeriodSelector
  periods : Array
Array of period buttons.
PeriodSelector
  periodsText : String
Text displayed next to predefined period buttons.
PeriodSelector
  position : String
Position of the Period Selector.
PeriodSelector
  selectFromStart : Boolean
Specifies whether predefined period buttons should select a period from the beginning or the end of the data.
PeriodSelector
  startDateField : DateField
DateField of start date.
PeriodSelector
  timeFieldsEnabled : Boolean
Specifies whether time input fields are displayed.
PeriodSelector
  toText : String
Text displayed next to "to" date input field.
PeriodSelector
  useTwelveHourFormat : Boolean
[write-only] Specifies whether time input fields should use twelve hour format.
PeriodSelector
Public Methods
 MethodDefined by
  
selectPeriodButton(periodButton:PeriodButton):void
Selects one of the predefined periods.
PeriodSelector
Events
 EventSummaryDefined by
   Dispatched when dates in period selector input fields are changed.PeriodSelector
Property detail
endDateFieldproperty
endDateField:DateField  [read-write]

DateField of end date. By default it is created automatically, however if you want to change date format or other property, you should set it here.

Implementation
    public function get endDateField():DateField
    public function set endDateField(value:DateField):void
fromTextproperty 
fromText:String  [read-write]

Text displayed next to "from" date input field.

The default value is From:.

Implementation
    public function get fromText():String
    public function set fromText(value:String):void
inputFieldsEnabledproperty 
inputFieldsEnabled:Boolean  [read-write]

Specifies whether period selector displays "from" and "to" date input fields.

The default value is true.

Implementation
    public function get inputFieldsEnabled():Boolean
    public function set inputFieldsEnabled(value:Boolean):void
limitToAvailableDatesproperty 
limitToAvailableDates:Boolean  [read-write]

If true, the period selector calendars won't allow selecting dates which are out of data providers range.

The default value is true.

Implementation
    public function get limitToAvailableDates():Boolean
    public function set limitToAvailableDates(value:Boolean):void
periodsproperty 
periods:Array  [read-write]

Array of period buttons.

Implementation
    public function get periods():Array
    public function set periods(value:Array):void
periodsTextproperty 
periodsText:String  [read-write]

Text displayed next to predefined period buttons.

The default value is Zoom:.

Implementation
    public function get periodsText():String
    public function set periodsText(value:String):void
positionproperty 
position:String  [read-write]

Position of the Period Selector.

The default value is bottom.

Implementation
    public function get position():String
    public function set position(value:String):void
selectFromStartproperty 
selectFromStart:Boolean  [read-write]

Specifies whether predefined period buttons should select a period from the beginning or the end of the data.

The default value is false.

Implementation
    public function get selectFromStart():Boolean
    public function set selectFromStart(value:Boolean):void
startDateFieldproperty 
startDateField:DateField  [read-write]

DateField of start date. By default it is created automatically, however if you want to change date format or other property, you should set it here.

Implementation
    public function get startDateField():DateField
    public function set startDateField(value:DateField):void
timeFieldsEnabledproperty 
timeFieldsEnabled:Boolean  [read-write]

Specifies whether time input fields are displayed. Time input fiels are displayed only if minPeriod of category axis is hh, mm, ss or fff. If you have daily data, these fields are not displayed anyway.

The default value is true.

Implementation
    public function get timeFieldsEnabled():Boolean
    public function set timeFieldsEnabled(value:Boolean):void
toTextproperty 
toText:String  [read-write]

Text displayed next to "to" date input field.

The default value is to:.

Implementation
    public function get toText():String
    public function set toText(value:String):void
useTwelveHourFormatproperty 
useTwelveHourFormat:Boolean  [write-only]

Specifies whether time input fields should use twelve hour format.

The default value is true.

Implementation
    public function set useTwelveHourFormat(value:Boolean):void
Method detail
selectPeriodButton()method
public function selectPeriodButton(periodButton:PeriodButton):void

Selects one of the predefined periods.

Parameters
periodButton:PeriodButton
Event detail
changedevent 
Event object type: com.amcharts.stock.events.PeriodSelectorEvent

Dispatched when dates in period selector input fields are changed.