Peter,
If it is the TreeView Control; try this
Gets or sets a TreeNode object that represents the selected node in the
TreeView control. Please start here"
http://longhorn.msdn.microsoft.com/l...webcontrols/c/
treeview/p/selectednode.aspx
<%@ Page Language="C#" %>
<script runat="server">
void SpacingIndex_Changed(Object sender, EventArgs e)
{
// Set the vertical spacing of the selected node based on the value
selected by the user.
LinksTreeView.SelectedNodeStyle.VerticalPadding =
Convert.ToInt32(SpacingList.SelectedItem.Text);
}
void ColorIndex_Changed(Object sender, EventArgs e)
{
// Set the foreground (font) color of the selected node based on
the value selected by the user.
LinksTreeView.SelectedNodeStyle.ForeColor =
System.Drawing.Color.FromName(ColorList.SelectedIt em.Text);
}
void Select_Change(Object sender, EventArgs e)
{
Message.Text = "You selected: " + LinksTreeView.SelectedNode.Text;
}
--------------------[color=blue]
>Thread-Topic: Simple question on Treeview?
>thread-index: AcQCF4+B4d7YB7S9Tay6VlBKJ7Y7hQ==
>X-Tomcat-NG: microsoft.public.dotnet.languages.csharp
>From: "=?Utf-8?B?UGV0ZXI=?=" <anonymous@discussions.microsoft.com>
>Subject: Simple question on Treeview?
>Date: Thu, 4 Mar 2004 10:36:08 -0800
>Lines: 6
>Message-ID: <4918A61A-5FC1-4540-874C-A4DB65B1ECBD@microsoft.com>
>MIME-Version: 1.0
>Content-Type: text/plain;
> charset="Utf-8"
>Content-Transfer-Encoding: 7bit
>X-Newsreader: Microsoft CDO for Windows 2000
>Content-Class: urn:content-classes:message
>Importance: normal
>Priority: normal
>X-MimeOLE: Produced By Microsoft MimeOLE V6.00.3790.0
>Newsgroups: microsoft.public.dotnet.languages.csharp
>Path: cpmsftngxa06.phx.gbl
>Xref: cpmsftngxa06.phx.gbl microsoft.public.dotnet.languages.csharp:226424
>NNTP-Posting-Host: tk2msftcmty1.phx.gbl 10.40.1.180
>X-Tomcat-NG: microsoft.public.dotnet.languages.csharp
>
>Hello,[/color]
Thanks for reviewing my question. I would like to know how can I
programmatically select a node?
Thanks in Advance
Peter[color=blue]
>[/color]
Cheers,
johnKn [MS-SDK]
-Please do not send email directly to this alias. This alias is for
newsgroup purposes only
-This posting is provided “AS IS” with no warranties, and confers no rights.
-To provide additional feedback about your community experience please send
e-mail to:
sdkcomm@microsoft.com