Board index » delphi » TListView under D3 - problem editing

TListView under D3 - problem editing

I've been trying to allow editing of a tlistview under D3 Pro. I set
editing to true, and I thought if the user clicks on an item, it would
go into edit mode and allow the user to type something else in.
However, it only occasionally goes into edit mode. Most the time it
doesn't allow it. Can someone offer advice on how to do this?

Also, is it possible to allow editing (in report style) of the second
column, the subitem, but not the listitem? I would like to have the
user type in the info right on the listview column and not have a
secondary input form if this is possible. Any ideas?

 

Re:TListView under D3 - problem editing


Quote
>I've been trying to allow editing of a tlistview under D3 Pro. I set
>editing to true, and I thought if the user clicks on an item, it would
>go into edit mode and allow the user to type something else in.
>However, it only occasionally goes into edit mode. Most the time it
>doesn't allow it. Can someone offer advice on how to do this?

Entering edit mode is completely automatic. Just set the ReadOnly property
to False. When the users clicks an item the second time, the item will be
edited and you'll receive the OnEditing event. In this event you can deceide
which items can be edited and which not by setting the AllowEdit variable to
True/False

Quote
>Also, is it possible to allow editing (in report style) of the second
>column, the subitem, but not the listitem? I would like to have the
>user type in the info right on the listview column and not have a
>secondary input form if this is possible. Any ideas?

No, you cannot at least not with the standard ComCtl32 based TListView. You
could do some inplace editing yourself, using hit-test information.

Gerrit Beuze

Other Threads