How to open modal dialog?

Mani SJ asked on February 5, 2020 22:39

I am getting error on line 3 in browser console as modalDialog('dialogUrl value inside') is not defined. 

var dialogUrl = ApplicationUrlHelper.GetElementDialogUrl("ModuleName", "ElementName");
dialogUrl = URLHelper.GetAbsoluteUrl(dialogUrl);
var dialogScript = ScriptHelper.GetModalDialogScript(dialogUrl , "Detail", "500", "500");

Recent Answers

Mani SJ answered on February 6, 2020 03:49

ScriptHelper.RegisterDialogScript(Control.Page); needs to be wriiten before GetModalDialogScript()

0 votesVote for this answer Mark as a Correct answer

   Please, sign in to be able to submit a new answer.