Code example for NumberPicker

Methods: setDisplayedValuessetMaxValuesetMinValue

0
     * @param dayOfMonth The initial day of the month. 
     * @param onDateChangedListener How user is notified date is changed by user, can be null. 
     */ 
    public void init(int min, int max, int step, int frequency,
            OnFrequencyChangedListener onFrequencyChangedListener) {
 
            mMin = min;
            mMax = max;
            mStep = step;
        mFrequency = frequency;
        mOnFrequencyChangedListener = onFrequencyChangedListener;
 
        updateSpinners(); 
    } 
    private void updateSpinnerRange() { 
        String[] khzStrings = getKHzStrings(mMin, mStep);
        int khzNumSteps = getKHzCount(mStep);
 
        if (mMHzPicker != null) {
           mMHzPicker.setMinValue(mMin/1000);
           mMHzPicker.setMaxValue(mMax/1000);