The control is automatically added to your Toolbox in Visual Studio and is automatically registered in the GAC (Global Assembly Cache) during installation of SftTree/NET. Please see Distributing SftTree/NET for information on how to distribute the control with your application.
.NET 10 projects use the control through its NuGet package, see Using SftTree/NET with .NET 10.
You can add a SftTree control to a form by dragging it from the Toolbox to the form.
If the control is missing from the Toolbox, please see "Manually Adding .NET Components To The Toolbox".
Once the control has been added to the form, you can access its property pages, product updates and product support page on the web.
In this example, we'll create a minimal tree control with just a few items.
VB
Imports Softelvdm.SftTreeNET
Imports Softelvdm.Controls
Public Class Form1
Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
Dim item As ItemClass
item = SftTree1.ItemCollection.Add("First")
item.Add("A Child Item")
item.Add("Another Child Item")
SftTree1.ItemCollection.Add("Second")
SftTree1.ItemCollection.Add("Third")
End Sub
End ClassC#
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
using Softelvdm.SftTreeNET;
using Softelvdm.Controls;
namespace WindowsApplication1 {
public partial class Form1 : Form {
public Form1() {
InitializeComponent();
}
private void Form1_Load(object sender, EventArgs e) {
ItemClass item = sftTree1.ItemCollection.Add("First");
item.Add("A Child Item");
item.Add("Another Child Item");
sftTree1.ItemCollection.Add("Second");
sftTree1.ItemCollection.Add("Third");
}
}
}This control has many properties and methods which you can use. This is a very simple example and doesn't even begin to exploit the capabilities of this control. Please take a moment to familiarize yourself with the classes and objects offered by the SftTree/NET control. Each class or object represents a specific area of the control and can be fully customized. Also make sure to run the demo which is included with this product and take a look at the included samples.