Use EPiServer user picker in code

Vote:
 

Hi, I'm trying to invoke the EPiServer user and group picker dialog from code (specifically in an action window plugin), and am having trouble getting it to work.

I'm invoking the OpenDialogUserAndGroupBrowser function in javascript, passing it a callback function, and the dialog is invoked OK. I can select users/groups, but if I click OK or Cancel in the dialog, the callback function isn't invoked and I get a script error.

Someone must have done this before? - BTW I need to retrieve users/and groups to populate DDS, not a page property.

Any ideas where I'm going wrong?

#59290
May 29, 2012 19:01
Vote:
 

I found this blog-post, which helped us in our project:

http://krompaco.nu/2010/11/episerver-user-picker-property-that-uses-the-built-in-membership-browser/

#59319
May 31, 2012 14:30
Vote:
 

Anders,

Thanks for the info - that works for me if I define a property as specified in the blog-post. In my case, I just want to use the dialog to populate a list of users/groups to be saved in DDS. I'm referencing all the correct .js files, and I can invoke the dialog OK, but clicking OK and Cancel does nothing, and if I close the dialog my original plugin page is then disabled. I guess it's something to do with my Callback function, but can't see what...

#59326
May 31, 2012 17:39
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.