Hi expert,
I'm using below function to open a modal dialog, in this modal dialog I need a people picker control, but not sure how to initialize it using SPClientPeoplePicker_InitStandaloneControlWrapper() function in my case because the content of the dialog are created on the fly.
function
AddNewDeckRequest(){
varMyHtmlElement ="....HTML string that contains a div with id=poplepicker_1...";
// Define the Modal's options
var
options = {
// define a URL (and yes, you can pass params to that URL) or reference your HTML object, but NOT both!
//url: '../MyPage.aspx?MyParam=' + SomeVar + '&IsDlg=1',
html:
MyHtmlElement,
title:"Add new deck request",
allowMaximize:
false,
showClose:
true,
width:
800,
height:
800
};
// This ensures the supporting JS needed is loaded on the page
SP.SOD.execute('sp.ui.dialog.js','SP.UI.ModalDialog.showModalDialog',
options);
}
Thanks,
Michael