Stay organized with collections
Save and categorize content based on your preferences.
NumberPicker.OnValueChangeListener
public
static
interface
NumberPicker.OnValueChangeListener
android.widget.NumberPicker.OnValueChangeListener
|
Interface to listen for changes of the current value.
Summary
Public methods |
abstract
void
|
onValueChange(NumberPicker picker, int oldVal, int newVal)
Called upon a change of the current value.
|
Public methods
public abstract void onValueChange (NumberPicker picker,
int oldVal,
int newVal)
Called upon a change of the current value.
Parameters |
picker |
NumberPicker : The NumberPicker associated with this listener. |
oldVal |
int : The previous value. |
newVal |
int : The new value. |
Content and code samples on this page are subject to the licenses described in the Content License. Java and OpenJDK are trademarks or registered trademarks of Oracle and/or its affiliates.
Last updated 2025-02-10 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-02-10 UTC."],[],[],null,["# NumberPicker.OnValueChangeListener\n\nAdded in [API level 11](/guide/topics/manifest/uses-sdk-element#ApiLevels) \n\nNumberPicker.OnValueChangeListener\n==================================\n\n*** ** * ** ***\n\n[Kotlin](/reference/kotlin/android/widget/NumberPicker.OnValueChangeListener \"View this page in Kotlin\") \\|Java\n\n\n`\npublic\nstatic\n\n\ninterface\nNumberPicker.OnValueChangeListener\n`\n\n\n`\n\n\n`\n\n|---------------------------------------------------|\n| android.widget.NumberPicker.OnValueChangeListener |\n\n\u003cbr /\u003e\n\n*** ** * ** ***\n\nInterface to listen for changes of the current value.\n\nSummary\n-------\n\n| ### Public methods ||\n|------------------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| ` abstract void` | ` `[onValueChange](/reference/android/widget/NumberPicker.OnValueChangeListener#onValueChange(android.widget.NumberPicker,%20int,%20int))`(`[NumberPicker](/reference/android/widget/NumberPicker)` picker, int oldVal, int newVal) ` Called upon a change of the current value. |\n\nPublic methods\n--------------\n\n### onValueChange\n\nAdded in [API level 11](/guide/topics/manifest/uses-sdk-element#ApiLevels) \n\n```\npublic abstract void onValueChange (NumberPicker picker, \n int oldVal, \n int newVal)\n```\n\nCalled upon a change of the current value.\n\n\u003cbr /\u003e\n\n| Parameters ||\n|----------|------------------------------------------------------------------------|\n| `picker` | `NumberPicker`: The NumberPicker associated with this listener. \u003cbr /\u003e |\n| `oldVal` | `int`: The previous value. \u003cbr /\u003e |\n| `newVal` | `int`: The new value. \u003cbr /\u003e |"]]