I have just started using WPF forms instead of Windows Forms forms. In a Windows Forms form I could just do:
ComboBox.SelectedValue.toString();
Actually you can do it the following way as well.
Suppose your ComboBox name is comboBoxA
. Then its value can be gotten as:
string combo = comboBoxA.SelectedValue.ToString();
I think it's now supported since your question is five years old.
MsgBox(cmbCut.SelectedValue().ToString())
Write it like this:
String CmbTitle = (cmb.SelectedItem as ComboBoxItem).Content.ToString()
How about these:
string yourstringname = (yourComboBox.SelectedItem as ComboBoxItem).Content.ToString();
To get the value of the ComboBox's selected index in C# use:
Combobox.SelectedValue
It's the same principle.
You can either use SelectedIndex and use ComboBox.Items[SelectedIndex].ToString(). Or just ComboBox.SelectedItem and cast it to any type you need :)