It's all about the answers!

Ask a question

[Resolved] Change component owner and visibility problem

Antoine Rougeot (612) | asked Jun 06 '14, 11:31 a.m.
edited Jul 01 '14, 4:47 a.m. by Ralph Schoon (61.8k33643)
Hi all,
I'm trying to use this function :
void arg0, IAuditableHandle arg1, IReadScope arg2, IProgressMonitor arg3);

In order to change a component's visibility and owner. I use it in this way :

getWorkspaceManager().setComponentOwnerAndVisibility(getComponentHandle(), getRepository().loggedInContributor(), IReadScope.FACTORY.createPublicScope(), null);

No error is raised, but when i check the visibility in the RTC Web UI for the component, it is always "Private".
I tried different IReadScope parameters, but the result is the same.

Does someone know what is wrong ? Is there a function that i have to use after to save changes ?

thanks in advance !

3 answers

permanent link
Tim Mok (6.6k38) | answered Jun 06 '14, 4:28 p.m.
That is the correct way to set the scope on the component. I can't see any reason why it wouldn't work. Is the code for getting the component handle correct?

permanent link
Antoine Rougeot (612) | answered Jul 01 '14, 4:11 a.m.
Thanks for you answers,
it works now, i think that my getComponentHandle() was wrong.

@sam detweiler : setting a public visibility with a specific owner works

permanent link
sam detweiler (12.5k6189201) | answered Jun 06 '14, 12:52 p.m.
I don't think it can be public AND owned by a specific user..

to get pubic I think a component has to be owned by a team or project area.

Your answer

Register or to post your answer.