I am working in C# .NET
If I want to invoke LabelEdit event of TreeView/ListView(property set to
true) from another event what should I do?

I was advised to send a LVM_EDITLABEL / TVM_EDITLABEL message to the
control.

But how to get the integer number for LVM_EDITLABEL / TVM_EDITLEVEL ? Or
which namespace/ref I need to add to direct access of the const value.
Please help me. Is there any way to get all those constants' hex value?

Re: Treeview issue by Jeff

Jeff
Fri Apr 16 07:53:00 CDT 2004

On Fri, 16 Apr 2004 17:45:26 +0530, "Anil" <not@noreply.com>
wrote:

>I am working in C# .NET
>If I want to invoke LabelEdit event of TreeView/ListView(property set to
>true) from another event what should I do?
>
>I was advised to send a LVM_EDITLABEL / TVM_EDITLABEL message to the
>control.
>
>But how to get the integer number for LVM_EDITLABEL / TVM_EDITLEVEL ? Or
>which namespace/ref I need to add to direct access of the const value.
>Please help me. Is there any way to get all those constants' hex value?
>

They will be in the .h files in C:\Program Files\Microsoft
Visual Studio .NET 2003\Vc7\include (or your equivalent if you
installed it elsewhere).

The easiest way to find what you need is to run grep over the
folder or use the IDE's find in files function on the Edit menu.

--
Jeff Gaines - Damerham Hampshire UK


Re: Treeview issue by =?ISO-8859-2?Q?Marcin_Grz=EAbski?=

=?ISO-8859-2?Q?Marcin_Grz=EAbski?=
Fri Apr 16 09:28:15 CDT 2004

Hi,

> I am working in C# .NET
> If I want to invoke LabelEdit event of TreeView/ListView(property set to
> true) from another event what should I do?
>
> I was advised to send a LVM_EDITLABEL / TVM_EDITLABEL message to the
> control.
>
> But how to get the integer number for LVM_EDITLABEL / TVM_EDITLEVEL ? Or
> which namespace/ref I need to add to direct access of the const value.
> Please help me. Is there any way to get all those constants' hex value?

Maybe this sample could help You:

private void button1_Click(object sender, System.EventArgs e) {
treeView1.Select();
treeView1.SelectedNode=treeView1.Nodes[0]; //e.g. first node
treeView1.SelectedNode.BeginEdit();
}

Regards

Marcin