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.
我需要提取 SharePoint 网站上的安全组以及列表 ID,以便我可以更新在查找字段中使用这些值的另一个列表。
Sharepoint Web 服务的新手并正在寻找一种简单的方法?
以下是您获取所有组及其名称和 ID 的代码
SPGroupCollection grpcolls = web.Groups; foreach(SPGroup grp in grpcolls) { string grpid = grp.ID.ToString(); string grpLoginName = grp.LoginName; string grpName = grp.Name; }