private void FloderTree_AfterSelect(object sender, TreeViewEventArgs e) { if (e.Node.Text.ToString() != "我的电脑")//判断是否为根节点 EnumDirectories(e.Node); else EnumDrives(e.Node); }
private void treeView1_AfterSelect(object sender, TreeViewEventArgs e) { switch (treeView1.SelectedNode.Name) { case "n00"://仿真时间 showthegroupbox(groupBox6); break; case "n10" ://发射站轨道 showthegroupbox(groupBox2); break; case "n11"://发射站雷达参数 showthegroupbox(groupBox3); break; case "n20"://接收站轨迹 showthegroupbox(groupBox1); break; case "n21"://接收站雷达参数 showthegroupbox(groupBox5); break; default: showthegroupbox(); break; } }
private void treeView1_AfterSelect(object sender, TreeViewEventArgs e) { string str; if (treeView1.SelectedNode.Name == "HDLogin") { str = Application.StartupPath + "\\Huongdan\\Login.mht"; webBrowser1.Navigate(str); } if (treeView1.SelectedNode.Name == "HD_HS") { str = Application.StartupPath + "\\Huongdan\\HD_HS.mht"; webBrowser1.Navigate(str); } if (treeView1.SelectedNode.Name == "HD_GV") { str = Application.StartupPath + "\\Huongdan\\HD_GV.mht"; webBrowser1.Navigate(str); } if (treeView1.SelectedNode.Name == "HD_TKB") { str = Application.StartupPath + "\\Huongdan\\HD_GV.mht"; webBrowser1.Navigate(str); } if (treeView1.SelectedNode.Name == "Nhom") { str = Application.StartupPath + "\\Huongdan\\Nhom.mht"; webBrowser1.Navigate(str); } if (treeView1.SelectedNode.Name == "PhanMem") { str = Application.StartupPath + "\\Huongdan\\GioiThieu.mht"; webBrowser1.Navigate(str); } }
private void trvHierarchy_AfterSelect(object sender, TreeViewEventArgs e) { this.XsdElementUri = null; if(e.Node.Tag is ProjectItem) { ProjectItem projectItem = e.Node.Tag as ProjectItem; if(!projectItem.Kind.Equals(Constants.vsProjectItemKindPhysicalFolder, StringComparison.OrdinalIgnoreCase)) { Cursor currentCursor = this.Cursor; this.Cursor = Cursors.WaitCursor; LoadXsdElementsHierarchy(e.Node); this.Cursor = currentCursor; } } else if(e.Node is XsdElementNode) { ProjectItem parent = e.Node.Parent.Tag as ProjectItem; this.XsdElementUri = new XmlSchemaElementMoniker(DteHelper2.BuildPath(parent), e.Node.Text); } if(SelectionChanged != null) { SelectionChanged(this, EventArgs.Empty); } }
private void treeView1_AfterSelect(object sender, TreeViewEventArgs e) { treeView1.PathSeparator = "/"; string path = treeView1.SelectedNode.FullPath.ToString(); int count = 0; for (int i = 0; i < path.Length; i++) { if (path[i].CompareTo('/') == 0) count++; } switch (count) { case 0: //第一级节点:显示用户组 listView1.Clear(); InsertAllColumns(0); AddItem_UserGrp(); break; case 1: //第二级节点:显示用户信息 listView1.Clear(); InsertAllColumns(1); AddItem_UserInfo(treeView1.SelectedNode.Text); break; case 2: //第三级节点:显示单个用户信息 listView1.Clear(); InsertAllColumns(2); AddItem_OneUserInfo(treeView1.SelectedNode.Text); break; } }
private void Node_Checked(object sender, TreeViewEventArgs e) { this.AfterCheck -= Node_Checked; CheckChildren(e.Node); CheckParent(e.Node); this.AfterCheck += Node_Checked; }
//after submit button is clicked private void btnSubmit_Click(object sender, EventArgs e) { //create datarow for a new row in the dataset DataRow newRow = Tracking.TaskEmployees.NewRow(); TreeViewEventArgs tve = new TreeViewEventArgs(tvProjects.SelectedNode); int projectTaskId; if(int.TryParse(tve.Node.Tag.ToString(), out projectTaskId)) { // set row data to controls newRow[0] = projectTaskId; newRow[1] = txtName.Text; newRow[2] = dtpDate.Value; newRow[3] = txtHours.Text; // add row to taskemployees dataset Tracking.TaskEmployees.Rows.Add(newRow); //create instance of a new treeview item ListViewItem itmTaskEmployees = new ListViewItem(txtName.Text); //add items to task employees itmTaskEmployees.SubItems.Add(dtpDate.Value.ToString()); itmTaskEmployees.SubItems.Add(txtHours.Text); //add item to listview lvWorkedTasks.Items.Add(itmTaskEmployees); } //clear controls and update statuslabel txtHours.Clear(); txtName.Clear(); thisParent.Status = "Hours Submitted!"; }
private void samplesTreeView_AfterSelect(object sender, TreeViewEventArgs e) { TreeNode currentNode = samplesTreeView.SelectedNode; currentSample = (Sample)currentNode.Tag; if (currentSample != null) { currentHarness = currentSample.Harness; runButton.Enabled = true; descriptionTextBox.Text = currentSample.Description; codeRichTextBox.Clear(); codeRichTextBox.Text = currentSample.Code; colorizeCode(codeRichTextBox); outputTextBox.Clear(); } else { currentHarness = null; runButton.Enabled = false; descriptionTextBox.Text = "Select a query from the tree to the left."; codeRichTextBox.Clear(); outputTextBox.Clear(); if (e.Action != TreeViewAction.Collapse && e.Action != TreeViewAction.Unknown) e.Node.Expand(); } }
private void testPointView_AfterSelect(object sender, TreeViewEventArgs e) { TreeNode tmpNode; ItemObject tmpObj; List<ItemObject> stack; if (e.Node == Root) return; //根节点返回 ItemObject itm = e.Node.Tag as ItemObject; listProperty(itm); #region 显示当前的item stack = new List<ItemObject>(10); tmpNode = e.Node; stack.Add(tmpNode.Tag as ItemObject); while ((tmpNode.Tag as ItemObject).type != PptType.Slide) { tmpNode = tmpNode.Parent; stack.Add(tmpNode.Tag as ItemObject); } while (stack.Count > 0) { try { tmpObj = stack[stack.Count - 1]; showSomething(tmpObj); stack.RemoveAt(stack.Count - 1); } catch { throw; } } #endregion }
private void nodeTreeView_AfterCheck(object sender, TreeViewEventArgs e) { if (isFoldNode(e.Node)) { foreach(TreeNode node in e.Node.Nodes) { node.Checked = e.Node.Checked; } } }
private void treeViewGroup_AfterSelect(object sender, TreeViewEventArgs e) { try { //Start of: Change Font of selected node if (prevNode != null) { prevNode.ForeColor = Color.Black; prevNode.NodeFont = new Font(Font.FontFamily, Font.Size, FontStyle.Regular); } prevNode = treeViewGroup.SelectedNode; treeViewGroup.SelectedNode.ForeColor = Color.Blue; treeViewGroup.SelectedNode.NodeFont = new Font(Font.FontFamily.Name, Font.Size, FontStyle.Regular); //End of: Change Font of selected node PrincipalContext ctx = new PrincipalContext(ContextType.Domain, treeViewGroup.SelectedNode.ImageKey); GroupPrincipal grp = GroupPrincipal.FindByIdentity(ctx, IdentityType.Name, treeViewGroup.SelectedNode.Text); userDetails = (from u in grp.Members select new UserDetails { DisplayName = u.DisplayName, UserName = u.SamAccountName,Domain = u.Context.Name }).OrderBy(x => x.DisplayName).ToList(); userControlListing.DataSource = userDetails; } catch (Exception) { throw; } }
private void tvNav_AfterSelect(object sender, TreeViewEventArgs e) { try { //--This is for "container" nodes so that when user pressess up arrow, the container node is skipped. if (e.Node.Tag == null && e.Node.Nodes.Count > 0) { if (!_lastKeywasUpArrow || e.Node.PrevNode == null) tvNav.SelectedNode = e.Node.Nodes[0]; else tvNav.SelectedNode = e.Node.PrevNode.LastNode; return; } //--using reflection here for performance reasons, this allows the application to delay-load the Action user control. if (e.Node.Tag.GetType().FullName == "System.RuntimeType") SetTreeNodeTagToActionParentInstance(e.Node); ActionParent ucp = (ActionParent)e.Node.Tag; splitContainer1.Panel2.Controls.Clear(); ucp.Dock = DockStyle.Fill; splitContainer1.Panel2.Controls.Add(ucp); ucp.ActionFormActivate(); if (ucp.PictureboxImage != null) this.pictureBoxTop.Image = ucp.PictureboxImage; rtbTitle.Text = " " + e.Node.Text; } catch (Exception ex) { Eh.GlobalErrorHandler(ex); } }
protected override void OnAfterSelect(TreeViewEventArgs e) { if (!only_focus) { base.OnAfterSelect(e); } }
private void tvwSideMenu_AfterSelect(object sender, TreeViewEventArgs e) { string selectedMenu = (string)e.Node.Tag; this.sustentantesUserControl.Visible = false; this.printerQueueUserControl.Visible = false; this.printerLoggingUserControl.Visible = false; this.templateConfigUserControl.Visible = false; this.printerConfigUserControl.Visible = false; if (selectedMenu == "Sustentantes") { this.sustentantesUserControl.Visible = true; } else if (selectedMenu == "PrinterQueue") { this.printerQueueUserControl.Visible = true; } else if (selectedMenu == "PrinterLogging") { this.printerLoggingUserControl.Visible = true; } else if (selectedMenu == "TemplateConfig") { this.templateConfigUserControl.Visible = true; } else if (selectedMenu == "PrinterConfig") { this.printerConfigUserControl.Visible = true; } }
private void afterSelectNode(object sender, TreeViewEventArgs e) { dc.listViewRows.Clear(); listView2.Items.Clear(); if (e.Node.Tag is HFSPlusCatalogFolder) { HFSPlusCatalogFolder details = (HFSPlusCatalogFolder)e.Node.Tag; propertyGrid1.SelectedObject = details; } else if (e.Node.Tag is HFSPlus.volumeHeader) { HFSPlus.volumeHeader details = (HFSPlus.volumeHeader)e.Node.Tag; propertyGrid1.SelectedObject = details; } else if (e.Node.Tag is absImageStream.imageProperties) { absImageStream.imageProperties details = (absImageStream.imageProperties)e.Node.Tag; propertyGrid1.SelectedObject = details; } dc.generateListViewContent(e.Node); foreach (ListViewItem row in dc.listViewRows) { listView2.Items.Add(row); } hashFileToolStripMenuItem.Enabled = true; }
private void MyTree_AfterCheck(object sender, TreeViewEventArgs e) { this.AfterCheck -= MyTree_AfterCheck; CheckChildren(e.Node); CheckParent(e.Node); this.AfterCheck += MyTree_AfterCheck; }
private void tv_AfterSelect(object sender, TreeViewEventArgs e) { try { data.BeginUpdate(); data.Nodes.Clear(); if (e != null && e.Node != null & e.Node.Tag != null) { foreach (System.Reflection.PropertyInfo pi in e.Node.Tag.GetType().GetProperties(System.Reflection.BindingFlags.FlattenHierarchy | System.Reflection.BindingFlags.Public | System.Reflection.BindingFlags.Instance)) { object v = pi.GetValue(e.Node.Tag, null); if (v == null) v = "<null>"; TreeNode n = data.Nodes.Add(pi.Name + ": " + v.ToString()); n.ExpandAll(); } foreach (System.Reflection.FieldInfo fi in e.Node.Tag.GetType().GetFields(System.Reflection.BindingFlags.FlattenHierarchy | System.Reflection.BindingFlags.Public | System.Reflection.BindingFlags.Instance)) { object v = fi.GetValue(e.Node.Tag); if (v == null) v = "<null>"; TreeNode n = data.Nodes.Add(fi.Name + ": " + v.ToString()); n.ExpandAll(); } } } finally { data.EndUpdate(); } }
private void treeView1_AfterSelect(object sender, TreeViewEventArgs e) { if(SelectedChanged!=null) { SelectedChanged(this, e); } }
private void treeView1_AfterSelect(object sender, TreeViewEventArgs e) { UserControl tag = null; if (this.panel.Controls.Count > 0) { foreach (Control control in this.panel.Controls) { try { this.panel.Controls.Remove(control); } catch (Exception) { } } } if ((e.Node.Tag != null) && (e.Node.Tag is UserControl)) { tag = e.Node.Tag as UserControl; } else if (e.Node is OptionNode) { tag = ((OptionNode)e.Node).UI; } if (tag != null) { tag.Dock = DockStyle.Fill; this.panel.Controls.Clear(); this.panel.Controls.Add(tag); } }
private void trvPdept_AfterSelect(object sender, TreeViewEventArgs e) { GetEmp(); //txtName.Text = ""; //lsbEmpMac.Items.Clear(); //lsbEmpMac.Values.Clear(); //string type; //if (rbtEmp.Checked) //{ // type = "人员"; //} //else //{ // type = "设备"; //} //if (trvPdept.SelectedNode != null) //{ // DataTable empmacdt = codebll.GetLastEmpByDept(trvPdept.SelectedNode.Name.Trim(), type,txtName.Text.Trim()); // empmacdt = RemoveExitsEmpMac(empmacdt); // for (int i = 0; i < empmacdt.Rows.Count; i++) // { // lsbEmpMac.AddItem(empmacdt.Rows[i][1].ToString(), empmacdt.Rows[i][0].ToString()); // } //} }
private void treeView1_AfterSelect(object sender, TreeViewEventArgs e) { pictureBox1.Image = null; label1.Text = null; Render(); RefreshMenu(); }
private void BuildConfigurationsAfterCheck(object sender, TreeViewEventArgs e) { if (e.Node.Tag == null) return; var buildDefinitionId = (string)e.Node.Tag; _ciEntryPointSetting.GetBuildDefinition(buildDefinitionId).Active = e.Node.Checked; Settings.Save(); }
private void OnAfterCheck(object sender, TreeViewEventArgs e) { this.AfterCheck -= OnAfterCheck; SetChildChecked(e.Node); SetParentChecked(e.Node); this.AfterCheck += OnAfterCheck; }
private void treeView_info_AfterExpand(object sender, TreeViewEventArgs e) { List<string> listmadoi = new List<string>(); if (e.Node.Name == "muagiai") { e.Node.Nodes.Clear(); this.doibonG_MUAGIAITableAdapter.FillByMaMua(this.quanLyGiaiVoDichDataSet.DOIBONG_MUAGIAI,e.Node.Tag.ToString()); foreach (DataRow row in this.quanLyGiaiVoDichDataSet.DOIBONG_MUAGIAI.Rows) { listmadoi.Add(row["MADOI"].ToString()); } foreach (string madoi in listmadoi) { this.doibongTableAdapter.FillByMadoi(this.quanLyGiaiVoDichDataSet.DOIBONG, madoi); foreach (DataRow r in this.quanLyGiaiVoDichDataSet.DOIBONG.Rows) { TreeNode doiNode = new TreeNode(); doiNode.Text = r["TENDOI"].ToString(); doiNode.Tag = madoi; doiNode.Name = "doi"; e.Node.Nodes.Add(doiNode); } } } }
/// <summary>ノード展開後イベント</summary> void WarlockTreeView_AfterExpand(object sender, TreeViewEventArgs e) { if (e.Node is WarlockTreeNode) { ((WarlockTreeNode)e.Node).OnAfterExpand(e); } }
private void proyectosVariasEtapasTvw_AfterSelect(object sender, TreeViewEventArgs e) { TreeNode node = proyectosVariasEtapasTvw.SelectedNode; if (node != null) { if (node.Tag != null) { PROYECTO prj = (PROYECTO)node.Tag; proyectoBS.DataSource = prj; numeroFormulariosTxt.Text=prj.FORMULARIO.Count.ToString(); int lineasInv = 0; int lineasRegen = 0; int lineasNoMader = 0; foreach (FORMULARIO frm in prj.FORMULARIO) { lineasInv += frm.LINEAINVENTARIO.Count; lineasRegen += frm.LINEAREGENERACION.Count; lineasNoMader += frm.LINEANOMADERABLES.Count; } numeroLineasInvTxt.Text = lineasInv.ToString(); numeroLinRegenTxt.Text = lineasRegen.ToString(); numeroLineasNoMadTxt.Text = lineasNoMader.ToString(); TipoProyectoCbx.SelectedValue = prj.TIPOPROYECTO; } } }
private void treeView1_AfterSelect(object sender, TreeViewEventArgs e) { if (treeView1.SelectedNode.Name == "rGioiThieu") { txtHD.Text = @"Đây là phần mềm hỗ trợ cho việc quản lý kho, bao gồm các công việc nhập hành, xuất hàng, tìm kiếm và thống kê hàng hóa ở trong kho. Phần mềm sẽ giúp cho công việc quản lí kho của chúng ta đạt hiệu quả cao hơn."; } else if (treeView1.SelectedNode.Name == "rLienHe") { txtHD.Text = "Mọi thông tin hay thắc mắc về phần mềm liên hệ \r\nSĐT: 0987890957 \r\nEmail: [email protected]"; } else if (treeView1.SelectedNode.Name == "nDangNhap") { txtHD.Text = "Để sử dụng phần mềm bạn cần có tài khoản. Bạn có thể liên hệ với tác giả trong phần thông tin liên hệ để đăng kí tài khoản"; } else if (treeView1.SelectedNode.Name == "nNhapHang") { txtHD.Text = @"Để nhập thêm hàng hóa, bạn click vào ô 'Nhập hàng', sau đó điền đầy đủ thông tin và click vào ô 'Nhập thêm' hoặc 'Nhập mới"; } else if (treeView1.SelectedNode.Name == "nXuatHang") { txtHD.Text = @"Để xuất hàng hóa, bạn chọn nội dung cần xuất trong danh sách ở dưới, sau đó sửa lại thông tin và click vào ô 'Xuất' để hoàn tất"; } else if (treeView1.SelectedNode.Name == "nTimKiem") { txtHD.Text = @"Để tìm kiếm nội dung nào đó, bạn nhập thông tin vào ô trống trong phần tìm kiếm sau đó click vào nội dung mình cần tìm kiếm"; } else if (treeView1.SelectedNode.Name == "nThongKe") { txtHD.Text = @"Để thống kê , bạn nhập click vào ô ' Thống kê nhập' hoặc 'Thống kê xuất"; } }
private void ExampleSelected(object sender, TreeViewEventArgs e) { try { TreeNode node = sideView.SelectedNode; if (node == null) { return; } if (node.Text.Equals("Users")) { usersControl.Visible = true; rolesControl.Visible = false; } else if (node.Text.Equals("Roles")) { rolesControl.Visible = true; usersControl.Visible = false; } } catch (Exception ex) { MessageBox.Show(ex.Message); } }
private void OnSelectedNode(object sender, TreeViewEventArgs e) { listViewDetails.Items.Clear(); EnumPEStructureId enumVal = (EnumPEStructureId)Enum.Parse(typeof(EnumPEStructureId), e.Node.Text); object objData = loader.DataStore.FileData[enumVal]; if (objData == null) return; Type type = objData.GetType(); if ((type.IsGenericType && type.GetGenericTypeDefinition() == typeof(Dictionary<,>)) || (type.IsGenericType && type.GetGenericTypeDefinition() == typeof(List<>))) return; PropertyInfo DataPi = type.GetProperty("Data"); object rawObjData = DataPi.GetValue(objData); foreach (var f in DataPi.PropertyType.GetFields().Where(f => f.IsPublic)) { if(f.FieldType.IsArray == true) { Array array = f.GetValue(rawObjData) as Array; string data = string.Empty; for (int indx = 0; indx < array.Length; ++indx) data += array.GetValue(indx); listViewDetails.Items.Add( new ListViewItem(new string[] { f.Name, data })); } else { listViewDetails.Items.Add( new ListViewItem(new string[] { f.Name, f.GetValue(rawObjData).ToString() })); } } }
private void TreeViewInvalidate(object sender, TreeViewEventArgs e) { if (this.treeView != null) { this.treeView.Invalidate(); } }
private void m_tvProdutos_AfterSelect(object sender, System.Windows.Forms.TreeViewEventArgs e) { fechaBalao(); if ((m_tvProdutosNormas.Nodes.Count == 0) && (m_lvNormas.Visible)) { mostraBalaoNormas(mdlMensagens.clsRepositorioMensagens.GetMensagem(mdlMensagens.Mensagem.BALLOONTIP_mdlProdutosCertificadoOrigem_frmFProdutosCertificadoOrigem_SelecionarNorma.ToString())); } else { mostraBalaoInsere(mdlMensagens.clsRepositorioMensagens.GetMensagem(mdlMensagens.Mensagem.BALLOONTIP_mdlProdutosCertificadoOrigem_frmFProdutosCertificadoOrigem_InserirProduto.ToString())); } }
private void treeView1_AfterSelect(object sender, System.Windows.Forms.TreeViewEventArgs e) { try { this.treeView2.Visible = false; SelectTree1Node("", e); } catch (System.Exception err) { MessageBox.Show("发生错误" + err.Message); } }
private void ObjectTree_AfterSelect(object sender, System.Windows.Forms.TreeViewEventArgs e) { var node = ObjectTree.SelectedNode; if (node == null) { ObjNameLabel.Text = "No Object Selected."; ObjDescLabel.Text = ""; ObjMultitileLabel.Text = ""; SelectedFile = null; SelectedObj = null; } ObjectRegistryEntry entry = null; SourceNodeToEnt.TryGetValue(node, out entry); if (entry == null) { //chose a filename ObjNameLabel.Text = node.Text + ".iff"; ObjDescLabel.Text = "Object File"; ObjMultitileLabel.Text = "Contains " + ObjectRegistry.MastersByFilename[node.Text].Count + " master objects."; SelectedFile = node.Text; SelectedObj = null; ObjThumbnail.ShowObject(0); } else { ObjNameLabel.Text = entry.Name; SelectedFile = entry.Filename; SelectedObj = entry; ObjThumbnail.ShowObject(entry.GUID); ObjDescLabel.Text = "§----"; if (entry.Group == 0) { ObjMultitileLabel.Text = "Single-tile object."; } else if (entry.SubIndex < 0) { ObjMultitileLabel.Text = "Multitile master object."; } else { ObjMultitileLabel.Text = "Multitile part. (" + (entry.SubIndex >> 8) + ", " + (entry.SubIndex & 0xFF) + ")"; } } if (SelectedChanged != null) { SelectedChanged(); } }
private void tvTypes_AfterCheck(object sender, System.Windows.Forms.TreeViewEventArgs e) { if (!updating) { GComposite comp = e.Node.Tag as GComposite; AppLayer.Update(comp.Id, e.Node.Checked); if (OnCompositeChecked != null) { OnCompositeChecked(this, new CompositeEventArgs(comp)); } app.CheckRepaint(comp); } }
//选中后显示模板内容 private void m_tvwTemplate_AfterSelect(object sender, System.Windows.Forms.TreeViewEventArgs e) { if (m_objTemplate != null) { string[] strTitle, strContent, strXml; m_objTemplate.m_mthGetTemplateNodeContent(e.Node, out strTitle, out strContent, out strXml); Color clrDefault = ctlRichTextBox.m_ClrDefaultViewText; ctlRichTextBox.m_ClrDefaultViewText = Color.Black; m_mthShowTemplateContent(strTitle, strContent, strXml); ctlRichTextBox.m_ClrDefaultViewText = clrDefault; } }
//======================================================================== private void treeView1_AfterSelect(object sender, System.Windows.Forms.TreeViewEventArgs e) { if (e.Node.Parent == null) { selectedNode = e.Node; CFG.EP ep = (CFG.EP)e.Node.Tag; this.last_selected_progid_ = ep.progid; this.behind_.status(ep.description); this.writeln(string.Empty); this.writeln(ep.request); this.writeln(string.Empty); } }
private void iTreeView_AfterSelect(object sender, System.Windows.Forms.TreeViewEventArgs e) { if (e.Node.Tag != null && e.Node.Tag is HeapCell) { HeapCell cell = (HeapCell)e.Node.Tag; // Update the raw cell view //ContentsViewerCell = cell; // Update the combined sizing (guesstimate) UpdateSizingTextBoxByType(); } }
private void _tvwMaint_AfterSelect(object sender, System.Windows.Forms.TreeViewEventArgs e) { switch (e.Node.Index) { case 0: AddCampaignsToLVW(); break; case 1: AddProductsToLVW(); break; } }
private void tvwMenuInfo_AfterCheck(object sender, System.Windows.Forms.TreeViewEventArgs e) { // The code only executes if the user caused the checked state to change. if (e.Action != TreeViewAction.Unknown) { if (e.Node.Nodes.Count > 0) { /* Calls the CheckAllChildNodes method, passing in the current * Checked value of the TreeNode whose checked state changed. */ this.CheckAllChildNodes(e.Node, e.Node.Checked); } } }
//////////////////////////////////////////////////////////////////////////////////////// private void m_arbreChamps_AfterExpand(object sender, System.Windows.Forms.TreeViewEventArgs e) { TreeNode node = e.Node; CDefinitionProprieteDynamique def = (CDefinitionProprieteDynamique)node.Tag; if (node.Nodes.Count == 1 && node.Nodes[0].Tag == null && node.Nodes[0].Text == "") { node.Nodes.Clear(); CObjetPourSousProprietes objetAnalyse = def.GetObjetPourAnalyseSousProprietes(); CreateNodesType(objetAnalyse, node.Nodes, def); node.Expand(); } }
private void trvWel_AfterSelect(object sender, System.Windows.Forms.TreeViewEventArgs e) { if (this.trvWel.SelectedNode.Parent == null) { this.m_strSelNodeType = "country"; return; } else { this.m_strSelNodeType = "zhan"; return; } }
private void allObjects_AfterSelect(object sender, System.Windows.Forms.TreeViewEventArgs e) { NDOTreeNode tn = e.Node as NDOTreeNode; if (tn != null) { this.propertyGrid1.SelectedObject = tn.Object; } else { this.propertyGrid1.SelectedObject = null; } }
/// <summary> /// /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void trvGroup_AfterSelect(object sender, System.Windows.Forms.TreeViewEventArgs e) { if (trvGroup.SelectedNode == trvGroup.Nodes[0]) { cmdApply.Enabled = false; lsvItemGroup.Items.Clear(); return; } cmdApply.Enabled = true; lsvItemGroup.Items.Clear(); m_mthInitializeGroupItem(); }
private void treeView1_AfterSelect(object sender, System.Windows.Forms.TreeViewEventArgs e) { TreeNode tn = e.Node; string strSummary = string.Empty; if (tn != null) { m_objController = new clsController_AppCheckContent(this); strSummary = m_objController.m_mthReturnNodeSummary(tn); this.txtSummary.Text = strSummary; } }
private void tvBrowser_AfterSelect(object sender, System.Windows.Forms.TreeViewEventArgs e) { this.ClearFileInfo(); object data = e.Node.Tag; FileInfo FI = data as FileInfo; if (FI == null) // Root or App Directory { if (e.Node.Parent == null) { this.txtLocation.Text = "<Root Node>"; } else { this.txtLocation.Text = data as string; } this.txtFileType.Text = "Folder"; } else // File { this.txtLocation.Text = FI.Location; this.txtTitle.Text = FI.Title; this.txtComposer.Text = FI.Composer; if (FI != null && FI.AudioFile != null) { switch (FI.AudioFile.Type) { case AudioFileType.SoundEffect: this.txtFileType.Text = "Sound Effect"; break; case AudioFileType.BGMStream: this.txtFileType.Text = "BGM Music Stream"; break; case AudioFileType.Unknown: this.txtFileType.Text = "Unknown Type"; break; } this.txtFormat.Text = String.Format("{0}-channel {1}-bit {2}Hz {3}", FI.AudioFile.Channels, FI.AudioFile.BitsPerSample, FI.AudioFile.SampleRate, FI.AudioFile.SampleFormat); this.txtFileLength.Text = this.LengthText(FI.AudioFile.Length); this.chkBufferedPlayback.Enabled = FI.AudioFile.Playable && this.AudioEnabled; this.btnDecode.Enabled = FI.AudioFile.Playable; this.btnPlay.Enabled = FI.AudioFile.Playable && this.AudioEnabled; } else { this.txtFileType.Text = "Folder"; } } }
/// <summary> /// Handles a TreeNode left-click selection. /// </summary> /// <param name="sender"></param> /// <param name="e"></param> public void TreeControl1AfterSelect(object sender, System.Windows.Forms.TreeViewEventArgs e) { try { // e.node.tag can be nothing if the node is a top level POS identifier // if we simply let the exception occur this seems to waste a lot of CPU power for some reason if ((e.Node.Tag != null)) { Wnlib.SynSet ss = (Wnlib.SynSet)e.Node.Tag; txtOutput.Text = ss.defn; } } catch { // when opening a root node } }
private void tvTypes_AfterSelect(object sender, System.Windows.Forms.TreeViewEventArgs e) { if (!updating) { if (OnCompositeSelected != null) { OnCompositeSelected(this, null); } if (app.GetControlsAttr(ControlsAttr.ShowPropertiesOnSelect)) { app.ShowProperties(SelectedComposite); } } }
private void treeView1_AfterSelect(object sender, System.Windows.Forms.TreeViewEventArgs e) { if (e.Node.Tag is Post) { SelectedPost = e.Node.Tag as Post; SelectedBlog = SelectedPost.Blog; UnlockFields(); } else { LockFields(); } }
private void treeView_RA_AfterSelect(object sender, System.Windows.Forms.TreeViewEventArgs e) { if (e.Action != TreeViewAction.Unknown) { if (e.Node.Tag.ToString().StartsWith("AuthorID@")) { this.button_View.Enabled = true; } else { this.button_View.Enabled = false; } } }
protected override void OnAfterSelect(System.Windows.Forms.TreeViewEventArgs e) { explicitlySelectedNode = null; if (!suppressEvents) { if (SelectedTestChanged != null) { SelectedTestChanged(SelectedTest); } base.OnAfterSelect(e); } }
private void treeView1_AfterSelect(object sender, System.Windows.Forms.TreeViewEventArgs e) { this.thumuc.Text = this.treeView1.GetSelectedNodePath(); try { listBox1.Items.Clear(); string [] files = Directory.GetFiles(this.thumuc.Text); for (int i = 0; i < files.GetLength(0); i++) { listBox1.Items.Add(files[i].ToString()); } } catch {} }
private void treeView1_AfterSelect(object sender, System.Windows.Forms.TreeViewEventArgs e) { if (e.Action == TreeViewAction.ByMouse) { try { string s = e.Node.FullPath.Trim(); int iPos = s.IndexOf("\\"); string s_mapt = s.Substring(iPos + 1, 3); load_grid(s_mapt); } catch {} } }
/** reacts on the event that a treeView node has been selected */ private void Service_Selected(Object sender, System.Windows.Forms.TreeViewEventArgs e) { // if it is the items node if (e.Node.Text.Equals("Items")) { // we switch to the item controller switchListController(itemController); } else if (e.Node.Text.Equals("BusinessPartners")) { // we switch to the business partner controller switchListController(businessPartnerController); } }
private void logTree_AfterSelect(object sender, System.Windows.Forms.TreeViewEventArgs e) { TreeNode selectedNode = logTree.SelectedNode; RefreshMainToolbar(); if (selectedNode.Parent == null) { RefreshEventLogList(); } else { RefreshEventEntryList(); } }
private void treeView_RA_AfterCheck(object sender, System.Windows.Forms.TreeViewEventArgs e) { if (e.Action != TreeViewAction.Unknown) { if (e.Node.Parent != null) { e.Node.Parent.Checked = e.Node.Checked; } if (e.Node.Nodes.Count > 0) { CheckAllChildNodes(e.Node, e.Node.Checked); } } }
private void treeView1_AfterExpand(object sender, System.Windows.Forms.TreeViewEventArgs e) { try { foreach (TreeNode tn in e.Node.Nodes) { if (!tn.IsExpanded) { getSubNode(tn, true); } } } catch { } }
private void TreeView1_AfterCheck(System.Object sender, System.Windows.Forms.TreeViewEventArgs e) { if (Check == true) { this.TreeView1.Enabled = false; Check = false; if (AfterCheckEvent != null) { AfterCheckEvent(sender, e); } Check = true; this.TreeView1.Enabled = true; } }
private void tvModelBrowser_AfterSelect(object sender, System.Windows.Forms.TreeViewEventArgs e) { TreeNode node = tvModelBrowser.SelectedNode; object element = model.FindElementByUniqueID((String)node.Tag); if (element.GetType() == typeof(UseCase)) { selected = (UseCase)element; this.lblUpperUseCase.Text = caller.Name; this.lblLowerUseCase.Text = selected.Name; this.btnOK.Enabled = true; this.btnSwap.Enabled = true; } }
private void tvArticles_AfterSelect(object sender, System.Windows.Forms.TreeViewEventArgs e) { if (isLoading || (e.Node == null)) { return; } isLoading = true; try { memBody.Lines = nntp1.GetBody(e.Node.Tag.ToString()); } finally { isLoading = false; } }
private void tvNavigation_AfterSelect(object sender, System.Windows.Forms.TreeViewEventArgs e) { this.chartFrame = new ChartFrame(); this.chartFrame.Location = new XPoint(30, 30); this.chartFrame.Size = new XSize(500, 600); Chart chart = null; switch (e.Node.Text.ToLower()) { case "line chart": chart = ChartSamples.LineChart(); break; case "column chart": chart = ChartSamples.ColumnChart(); break; case "stacked column chart": chart = ChartSamples.ColumnStackedChart(); break; case "bar chart": chart = ChartSamples.BarChart(); break; case "stacked bar chart": chart = ChartSamples.BarStackedChart(); break; case "area chart": chart = ChartSamples.AreaChart(); break; case "pie chart": chart = ChartSamples.PieChart(); break; case "pie exploded chart": chart = ChartSamples.PieExplodedChart(); break; case "combination chart": chart = ChartSamples.CombinationChart(); break; } this.chartFrame.Add(chart); this.pagePreview.SetRenderEvent(new PagePreview.RenderEvent(chartFrame.Draw)); }