RestrictionEntry.SetChoiceValues Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
SetChoiceValues(String[]) |
Sets a list of string values that can be selected by the user. |
SetChoiceValues(Context, Int32) |
Sets a list of string values that can be selected by the user, similar to
|
SetChoiceValues(String[])
Sets a list of string values that can be selected by the user.
[Android.Runtime.Register("setChoiceValues", "([Ljava/lang/String;)V", "GetSetChoiceValues_arrayLjava_lang_String_Handler")]
public virtual void SetChoiceValues (string[]? choiceValues);
[<Android.Runtime.Register("setChoiceValues", "([Ljava/lang/String;)V", "GetSetChoiceValues_arrayLjava_lang_String_Handler")>]
abstract member SetChoiceValues : string[] -> unit
override this.SetChoiceValues : string[] -> unit
Parameters
- choiceValues
- String[]
an array of Strings which will be the selected values for the user's selections.
- Attributes
Remarks
Sets a list of string values that can be selected by the user. If no user-visible entries are set by a call to #setChoiceEntries(String[])
, these values will be the ones shown to the user. Values will be chosen from this list as the user's selection and the selected values can be retrieved by a call to #getAllSelectedStrings()
, or #getSelectedString()
, depending on whether it is a multi-select type or choice type. This method is not relevant for types other than #TYPE_CHOICE
, and #TYPE_MULTI_SELECT
.
Java documentation for android.content.RestrictionEntry.setChoiceValues(java.lang.String[])
.
Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.
See also
Applies to
SetChoiceValues(Context, Int32)
Sets a list of string values that can be selected by the user, similar to
#setChoiceValues(String[])
.
[Android.Runtime.Register("setChoiceValues", "(Landroid/content/Context;I)V", "GetSetChoiceValues_Landroid_content_Context_IHandler")]
public virtual void SetChoiceValues (Android.Content.Context? context, int stringArrayResId);
[<Android.Runtime.Register("setChoiceValues", "(Landroid/content/Context;I)V", "GetSetChoiceValues_Landroid_content_Context_IHandler")>]
abstract member SetChoiceValues : Android.Content.Context * int -> unit
override this.SetChoiceValues : Android.Content.Context * int -> unit
Parameters
- context
- Context
the application context for retrieving the resources.
- stringArrayResId
- Int32
the resource id for a string array containing the possible values.
- Attributes
Remarks
Sets a list of string values that can be selected by the user, similar to #setChoiceValues(String[])
.
Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.