WindowsCommunityToolkit
WindowsCommunityToolkit copied to clipboard
Unable to bind to TokenizingTextBox SelectedItems
Describe the problem
I have a TokenizingTextBox control that I would like to bind to like this:
Page.xaml:
<controls:TokenizingTextBox
SelectedItems="{x:Bind Viewmodel.SelectedItems, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}"
TokenDelimiter=","/>
PageViewModel.cs:
public List<string> SelectedItems {get; set;} = new List<string>();
However this is not possible because SelectedItems is not a dependency property, and you can only access it in the code behind.
Describe the solution
I'm not sure. That's why I'm asking here. Right now, the way I am doing it is by manually updating the variable in the code behind on the focus lost event.
Alternatives
No response
Additional info
No response
Help us help you
No response
Hello, 'lukedukeus! Thanks for submitting a new feature request. I've automatically added a vote 👍 reaction to help get things started. Other community members can vote to help us prioritize this feature in the future!