There are three objects that can have tooltip: the node's text, the node's image
and node's text image.
This topic will show how to customize tooltip using several ways.
To assign Tooltip using WebTreeView DataBindings Editor
- Bind WebTreeView to XMLDataSource.
(Use Sample.xml)
- Open WebTreeView DataBindings Editor.
- To configure the node's text tooltip, set the ToolTipField
property.
- To configure the node image's tooltip, set the ImageToolTipField
property.
- To configure the text image's tooltip, set the TextImageToolTipField
property.
- Run the project.
To assign Tooltip using predefineds Tooltip's fields
- Bind WebTreeView to XMLDataSource.
(Use Sample.xml)
- Open WebTreeView DataBindings Editor.
- To configure the node's text tooltip, set the ToolTip property.
- To configure the node image's tooltip, set the ImageToolTip property.
- To configure the text image's tooltip, set the TextImageToolTip
property.
- Run the project.
To assign Tooltip using InitializeNode server-side event
- Bind WebTreeView to XMLDataSource.
(Use Sample.xml)
- Put the following code in InitializeNode server-side event to assign tooltip.
protected void WebTreeView3_InitializeNode(object sender, ISNet.WebUI.WebTreeView.WebTreeViewNodeEventArgs e)
{
e.Node.ToolTip = "ToolTip [Assigned from server side during InitializeNode]";
e.Node.ImageToolTip = "Image ToolTip [Assigned from server side during InitializeNode]";
e.Node.TextImageToolTip = "TextImage ToolTip [Assigned from server side during InitializeNode]";
}
|
- Run the project.