c-sharpcorner.com/forums/how-do-i-convert-a-list-element-to-text
The response does not convert to an xaml text box.
How do I convert a list element to text? ... Continued.
c-sharpcorner.com/forums/how-do-i-convert-a-list-element-to-text
The response does not convert to an xaml text box.
How do I convert a list element to text? ... Continued.
Know the answer? Post it. Somebody with the same question will find it here.
Answer a question in the forums and earn +20 SHARP for every answer.
See unanswered questions
DevSocialUpcoming · 3rd editionAI Agents ConferenceDec 1–3, 2026Live onlineFree to attend5days leftRegister
Jignesh KumarRank #91 · 22.9K reputationPosted Nov 30, 2024, 9:52 AM EST
List liststStringParsed = new List(); liststStringParsed.Add("a"); liststStringParsed.Add("b"); liststStringParsed.Add("c"); gTBxChar2.Text = liststStringParsed[2];OR
// Combine list values with a comma and assign to the TextBox gTBxChar2.Text = string.Join(", ", liststStringParsed);Sangeetha SRank #212 · 11.4K reputationPosted Dec 3, 2024, 12:11 AM EST
List myList = new List { "Item1", "Item2", "Item" }; string text = myList[0].ToString();If you're working with WPF and want to display this text in a XAML TextBox, you can do it like this:
C# code
myTextBox.Text = myList[0].ToString();