Version

ValueChanging Property (TextEditorClientEvents)

Gets sets name of javascript function which is called before value is changed.
Syntax
'Declaration
 
Public Property ValueChanging As String
public string ValueChanging {get; set;}
Remarks

Action can be canceled.

Example
Editor.ClientEvents.ValueChanging = "Editor_ValueChanging"
Editor.ClientEvents.ValueChanging = "Editor_ValueChanging";
// The client event 'ValueChanging' takes two parameters sender and e
// sender  is the object which is raising the event
// e is the TextEditorValueChangingEventArgs

//ID of the editor raising the event is "Editor"

function Editor_ValueChanging(sender, e) {

    //Gets the old value in the editor
    var oldValue = e.get_oldValue();

    //Gets the new value in the editor
    var newValue = e.get_value();

    if (!confirm("Are you sure you want to change the value '" + oldValue + "' to '" + newValue + "?"))

        //Cancels the ValueChanging event
        e.set_cancel(true);

}
Requirements

Target Platforms: Windows 10, Windows 8.1, Windows 8, Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also