Hello. You have 2 options: - use the plugin $xwiki.userdirectory , and more precisely this function: http://maven.xwiki.org/site/docs/xwiki-javadoc-4.1.x/com/xpn/xwiki/plugin/userdirectory/UserDirectoryPluginAPI.html#addUserToGroup%28java.lang.String,%20java.lang.String,%20com.xpn.xwiki.XWikiContext%29, but the plugin is deprecated. - or add an XWiki.XWikiGroups object on that group.
Regards, Louis-Marie 2013/4/3 Paul Libbrecht <[email protected]> > Hello Jordi and Andreas, > > why is it not as simple as just adding an object to the group document? > > paul > > > > > On 3 avr. 2013, at 12:30, jordiduran wrote: > > > Hi Adreas, > > > > I'm the same problem as you, have you got the solution? > > > > Thanks! > > > > > > > > -- > > View this message in context: > http://xwiki.475771.n2.nabble.com/How-to-add-a-user-to-a-group-programmatically-tp7386214p7584578.html > > Sent from the XWiki- Dev mailing list archive at Nabble.com. > > _______________________________________________ > > devs mailing list > > [email protected] > > http://lists.xwiki.org/mailman/listinfo/devs > > _______________________________________________ > devs mailing list > [email protected] > http://lists.xwiki.org/mailman/listinfo/devs > _______________________________________________ devs mailing list [email protected] http://lists.xwiki.org/mailman/listinfo/devs

