Treeview issue

  • Thread starter Thread starter Anil
  • Start date Start date
A

Anil

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?
 
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.
 
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
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top