Esempio n. 1
0
        private void CheckAndRemove(SPNavigationNodeCollection topNavi)
        {
            var nodes = from n in topNavi.Cast <SPNavigationNode>()
                        where n.Title.Equals("HR Department")
                        select n;

            if (nodes.Count() == 1)
            {
                topNavi.Delete(nodes.First());
            }
        }