Discussions
Categories
Groups
Community Home
Categories
INTERNAL ENABLEMENT
POPULAR
PUBLIC CLOUD
PRIVATE CLOUD
Quick Links
MY LINKS
HELPFUL TIPS
Back to website
Home
Web CMS (TeamSite)
GetWorkspaces
msmelb
Hi,
I would like to consume the GetWorkspaces Webmethod to get a list of all the workspaces for a logged on user.
Could you please help.
I understand that following are the input parameters:
public string[] ObjectIDs;
public imProfileAttributeID[] OutputProfile;
public OutputMask OutputMask;
How would I know the object ids??
protected void GetAllWorkSpaces()
{
IWOVServices WSWSvcs = new IWOVServices();
WSWSvcs.PreAuthenticate = true;
WSWSvcs.AllowAutoRedirect = true;
WSWSvcs.Credentials = System.Net.CredentialCache.DefaultCredentials;
}
Help highly appreciated.
Thanks
Find more posts tagged with
Comments
hks
If you want to get a list of workspaces for the current logged in user, you should be using the SearchWorkspaces web method with proper search parameters instead of the GetWorkspaces web method.
The Get Workspaces web method is for getting the properties of a workspace or multiple workspace.
msmelb
Yep Thanks,
I have got the bit of code..
Could you please help..which property needs to be searched for the logged in user??
// Workspace profile values by which to search.
ProfileSearchParameter[] arrProfParams = new ProfileSearchParameter[1];
arrProfParams[0] = new ProfileSearchParameter();
arrProfParams[0].AttributeID = imProfileAttributeID.imProfileAuthor;
arrProfParams[0].SearchValue = "Test";
// Workspace property values by which to search.
FolderSearchParameter[] arrFldrParams = new FolderSearchParameter[1];
arrFldrParams[0] = new FolderSearchParameter();
arrFldrParams[0].AttributeID = imFolderAttributeID.imFolderOwner;
arrFldrParams[0].SearchValue = "Test";
hks
You can set either of these 2 properties (imProfileAttributeID.imProfileAuthor or imFolderAttributeID.imFolderOwner) and it should return to the workspaces for which the set user is owner/author.
Arwin
Do you want to find workspaces for which the user is the owner, or do you want to find the workspaces in a user's mymatters folder? The latter is a subscription folder that you can search for using type S and parent = NULL, for instance. This special folder contains all workspaces that a user has added to his mymatters folder.