I am attempting to fill a Treeview using an array filled with instances of a class I created. There are no errors, but nothing appears in the view. Here is the code I am using to fill the Tree. It is placed in the form Constructer.
for (int index = 0; index < jobArray.Length - 1; index++)
{
TreeNode newNode = new TreeNode();
newNode.Text = jobArray[index].name;
newNode.Tag = jobArray[index].trusses;
treeView1.Nodes.Add(newNode);
}
Any Suggestions? thanks!
If you change the condition in the loop (-1) it should work fine: