Autocomplete
Autocomplete component for Universal Apps
The autocomplete is a normal text input enhanced by a panel of suggested options.
Static List of Options
Creates a basic autocomplete with a static list of options
Dynamic List of Options
When text is typed, it can be filtered with OnLoadOptions
. $Body
will contain the current text that is typed.
This example filters the array with Where-Object
.
OnChange
$Body
contains the currently selected item. The OnChange event will fire when the user selects one or more items.
Icon
![](https://docs.powershelluniversal.com/~gitbook/image?url=https%3A%2F%2F1373299915-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252F8F6PrkNTG8Y34hADzKOL%252Fuploads%252Fgit-blob-af3fbff6b7095264605df55ddff471967fdf3223%252Fimage%2520%28169%29.png%3Falt%3Dmedia&width=768&dpr=4&quality=100&sign=d1b0ae05&sv=1)
You can place an icon before an autocomplete by using the -Icon
parameter.
OnEnter
OnEnter is triggered when the user presses the enter key within the autocomplete.
Options
You can use New-UDAutoCompleteOption
to specify name and values.
API
Last updated