Created
October 3, 2015 11:09
-
-
Save KennethanCeyer/0c6973a8e31dc378164c to your computer and use it in GitHub Desktop.
ListView TextWrapping using TextBlock
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ListBoxItem lb = new ListBoxItem(); | |
TextBlock tb = new TextBlock(); | |
/* ListView TextWrapping using TextBlock. */ | |
tb.TextWrapping = TextWrapping.Wrap; | |
tb.Text = data; | |
lb.Content = tb; | |
MainChatList.Items.Add(lb); | |
MainChatList.SelectedIndex = MainChatList.Items.Count - 1; | |
MainChatList.ScrollIntoView(MainChatList.Items[MainChatList.Items.Count - 1]); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment