// add new camera private void cameraAddMenu_Click(object sender, EventArgs e) { // show dialog box VsCameraDialog cameraDialog = new VsCameraDialog(vsCoreMonitor); cameraDialog.ShowDialog(this); // update tree list if (cameraDialog.DialogResult == DialogResult.OK) { TreeNode retNode = this.camerasNode.Nodes.Add(cameraDialog.Camera.CameraName); retNode.ImageIndex = 4; retNode.SelectedImageIndex = 4; retNode.EnsureVisible(); } }