473,396 Members | 1,935 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Check Whether SharePoint Group Exists

I was wondering if there was any way to programmatically determine
whether or not a group exists in SharePoint. I checked the
SPGroupCollection in the SPWeb.SiteGroups property and didn't see any
methods for doing lookups. I could obviously write my own code that
loops through each group, but I was wondering if there was an
easier/cleaner way to accomplish this task.

Thank you in advance,

--
Sean
Sep 26 '07 #1
1 7824
On Sep 26, 9:53 pm, "Fao, Sean" <enceladus...@yahoo.comI-WANT-NO-SPAM>
wrote:
I was wondering if there was any way to programmatically determine
whether or not a group exists in SharePoint. I checked the
SPGroupCollection in the SPWeb.SiteGroups property and didn't see any
methods for doing lookups. I could obviously write my own code that
loops through each group, but I was wondering if there was an
easier/cleaner way to accomplish this task.

Thank you in advance,

--
Sean
what about loop?

foreach(SPGroup spGroup in spWeb.SiteGroups)
{
....
}

Sep 26 '07 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

7
by: andylcx | last post by:
Hi all: The c++ language can check whether the file exist or not. I am wondering how c language does this job? Thanks a lot! Andy
6
by: Michael S | last post by:
Not sure if I'm posting in the right group but here goes. I am getting the following error when trying to browse to an .aspx page which I have set up in a virtual directory under the default...
3
by: Robin | last post by:
I am trying to get a virtual directory ASP.Net application to work on a Windows 2003 server that has Sharepoint 2003. I have followed the Microsoft knowledgebase but the error message below still...
15
by: (PeteCresswell) | last post by:
Got a sample of MS's "Advisor Guide To Microsoft Access" in the mail today - accompanied by a sample "Advisor Guide To Microsoft SharePoint". I skimmed both, but the SharePoint explanation is too...
4
by: Ronald S. Cook | last post by:
I've always used Visual SourceSafe for checking in/out source code. We also used it for deliverables (e.g. functional specification document), but should we be using SharePoint for that instead? ...
20
by: Neil | last post by:
What is Sharepoint, and should I care?
1
by: tagg3rx | last post by:
Hi all, I'm trying to figure out how to facilitate a window in my web application that will allow users to drag and drop files into it which will inturn trigger the files being uploaded to my...
0
by: =?Utf-8?B?U2FkaG5h?= | last post by:
HI , I am using MOSS 2007 API's to implement the version controls like check in and check out in Visual Studio 2005. I have a sharepoint 2007 server and i am accessing the MOSS API (on...
1
by: ykhamitkar | last post by:
Hi there, can anyone help me for the code to check if a file exists on the sharepoint link and what object I need to pick up from the reference(if any) Thanks Yogesh
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.