Пример #1
0
 private void createNewRegistryKey_Click(object sender, EventArgs e)
 {
     if (!(tvRegistryDirectory.SelectedNode.IsExpanded) && tvRegistryDirectory.SelectedNode.Nodes.Count > 0)
     {
         //Subscribe (wait for node to expand)
         tvRegistryDirectory.AfterExpand += this.createRegistryKey_AfterExpand;
         tvRegistryDirectory.SelectedNode.Expand();
     }
     else
     {
         _registryHandler.CreateRegistryKey(tvRegistryDirectory.SelectedNode.FullPath);
     }
 }