Combo box values
I am trying to create a Windows Form App.
I am trying to work out a cost when someone selects a value.
Basically I want them to select a value and have a cost associated with that value.
Does anyone know how to make it so an item in a combo box has text and then also a integer value associated with it so I can use it to work out the total cost.
For example I am trying to make it so different types of insurance have different values.
None - I want this to have 0 cost
Basic - I want this to have 10 cost
Full - I want this to have 25 cost
I have tried using chat gpt but it isn't working for me I cant get what im looking for
2 Replies
ListControl.DisplayMember Property (System.Windows.Forms)
Gets or sets the property to display for this ListControl.
Basically has all the samples you could need 🙂