Bernhard
Bernhard

Reputation: 1485

Add combobox to ListViewItem

I'm creating a Windows Form application using C#. The form contains a ListView. It's an application for a Red Cross Dispatcher.

The ListView has a list of all units. Each unit has a status. This status needs to be changeable. Therefore I want to add a comboBox with all available statuses to each ListViewItem. The Statuses are stored in a MySql database.

How can I do this?

Upvotes: 4

Views: 34028

Answers (1)

Hans Olsson
Hans Olsson

Reputation: 55049

Here's a Microsoft sample article showing exactly how to do this: How to use a ComboBox control to edit data in a ListView control in Visual C#

You'll just have to change how it loads its data.

Upvotes: 7

Related Questions