Skip to content

Replies

0
Kyle Wingate
Kyle Wingate answered on Nov 16, 2015 6:47 PM

Thanks a ton, Petko, and I hope this serves someone in the future. 

I needed a way to see if the widget had been initialized before i can destroy it because if you try to destory the widget before initialization an error is thrown.

I think I've found a solution for that:

// Check if the HTML Editor control has been initalized

if (typeof $("#htmlEditor").igHtmlEditor() !== "undefined") {

    // Destroys HTML Editor control
    $("#htmlEditor").igHtmlEditor("destroy");
}

0
Kyle Wingate
Kyle Wingate answered on Nov 16, 2015 3:00 PM

I’ve attached a sample with the aforementioned code in Controllers/ScriptController and Model/CRMScript

IgniteUIHTMLEditorExample