Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
仍然试图围绕来自 Java 和 Objective-C 世界的 LINQ。有没有办法用 LINQ 完成以下循环?
foreach(MyData d in mydata) { TreeNode n = new TreeNode(d.DisplayName); this.myTree.Nodes.Add(n); }
myTree.Nodes.AddRange(myData.Select(n => new TreeNode(n.DisplayName)).ToArray());
尝试,