Tony Stark Tony Stark - 5 months ago 34
C# Question

Take an input from a combo box in Windows Mobile Applications

I have the following combo box in the Mobile App

<ComboBox name="cmb_tax" Grid.Row="2" Grid.Column="1">
<ComboBoxItem content="10%" />
<ComboBoxItem content="20%" />
<ComboBoxItem content="30%" />
</ComboBox>


and want to take the value passed from this to a string variable. Thank you in advance.

Answer Source
((ComboBoxItem)cmb_tax.SelectedItem).Content.ToString();