C#C
C#3y ago
Gipper

❔ Anyone knows how to have a "default value" in a ComboBox?

I mean like before even clicking the button to open the scroll-down menu, already having some text written down in there...Something like "Please Select" or maybe the last option in the ComboBox selected...
And if you google it and find a StackOverflow thread where they explain how to do it, that doesn't work for me cause I'm doing it by creating a list of strings in the code that's behind the XAML with the strings that will show up as options in the ComboBox whereas they're doing it all directly in the XAML which if I do it in the "behind" code and also put stuff inside the <ComboBox/> tag it will throw up an exception, and I don't know how to put all the data directly in the XAML...
Was this page helpful?