Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Editable ListView

Tags:

I am looking to create an editable ListView in a C# winforms application where a user may double click on a cell in order to change its contents. It would be great if someone could provide my with some guidance and/or an example. I am not looking to use any commercial products.

like image 984
THE DOCTOR Avatar asked Apr 30 '09 19:04

THE DOCTOR


People also ask

How to make ListView Editable in c#?

You could use the listview's DoubleClick event, and when it is called, you would open a new form where the user would enter a new value for the selected item. Then when the user has pressed ok, you would edit the value of the specific item to what the user has entered.

How to make ListView Editable in Vb net?

You can enable inline editing of ListView items in C# simply by setting ListView's LabelEdit property to True (all ideas from this article also work in VB.NET after corresponding syntax changes): listView1. LabelEdit = true; But you cannot enable editing of ListView subitems by setting a similar property.

How do you make an editable list on flutter?

How do I make an editable ListView item? Use TextField instead of Text Widget & pass Dynamic data as Initial data - then on edit enable that TextField & edit Text. thanks, but TextField is editable anyway. when user clicks accidentally it can enter any text.


1 Answers

You're asking the wrong question :)

A ListView is not the correct control. Use the DataGridView control. It can be configured to look just like a ListView, but it supports in-place editing of cells.

like image 98
Simon Gillbee Avatar answered Oct 11 '22 10:10

Simon Gillbee