frosty
frosty

Reputation: 5370

Ext.getCmp not returning current value of html editor

I'm getting inconstant results using Ext.getCmp on my htmlEditor.

I'm noticing that it is returning the value of the property on page load but not the updated value.

onSubmitBtnClick: function () {

        var notes = Ext.getCmp('notes').value; 
      // this value is not the current value in the editor. 
}

Upvotes: 1

Views: 1833

Answers (1)

egerardus
egerardus

Reputation: 11486

.value is configuration of what the field initializes with. Try .getValue() instead.

onSubmitBtnClick: function () {

    var notes = Ext.getCmp('notes').getValue(); 
}

Upvotes: 2

Related Questions