Results 1 to 3 of 3

Thread: Can't get value of bound textbox

  1. #1
    Sencha Premium Member
    Join Date
    Feb 2015
    Location
    Israel
    Posts
    114
    Answers
    3

    Default Can't get value of bound textbox

    I have a grid and whenever I select a row in that grid, some textbox in some form changes automatically. I bound the grid row to the textfield.

    Now, the textfield contains a date. I wanna convert the date from Date() type to a string in the form of d/m/YY. Unlike displayfield or grid lines or datefield, I cannot use a formatter nor a renderer, so I tried to use a listener to afterrender to the textfield.

    Unfortunately, I noticed the bound value does not appear this way and I cannot convert the Date to a string...

    I guess I'll just extract the date from the grid itself and set the textfield value to it after converting to string, It's a lot easier and quicker.

    But still I'm wonder: is there a way to get bound data from a textfield and convert it using a listener?

  2. #2
    Sencha Premium User
    Join Date
    Apr 2007
    Location
    Sydney, Australia
    Posts
    19,258
    Answers
    759

    Default

    Use a formula to transform data.

  3. #3
    Sencha Premium Member
    Join Date
    Feb 2015
    Location
    Israel
    Posts
    114
    Answers
    3

    Default more help

    Thanks.

    I've been reading the API and everything and still haven't figured out how to use it. Mind if you supply me some example code?

Similar Threads

  1. [FIXED] Ext.mixin.Bindable.removeBindings Exception
    By FBNitro in forum Ext JS 6.x Bugs
    Replies: 6
    Last Post: 21 Feb 2018, 12:41 AM
  2. Bindable triggers
    By chramer in forum Ext 5: Q&A
    Replies: 2
    Last Post: 31 Dec 2014, 9:38 AM
  3. Bindable (Observable subclass)
    By ldaley in forum Community Discussion
    Replies: 8
    Last Post: 23 May 2007, 4:56 PM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •