Thank you for reporting this bug. We will make it our priority to review this report.
  1. #1
    Touch Premium Member
    Join Date
    Dec 2010
    Posts
    25
    Vote Rating
    0
    vgribok is on a distinguished road

      0  

    Default 1.1: Toggle field setValue() causes an exception

    1.1: Toggle field setValue() causes an exception


    Using ST 1.1.

    Trying to replace a checkbox on a floating form panel with a toggle. Replacing checkbox's check() and uncheck(), which worked perfectly, with toggle's setValue(1) and setValue(0), causes an exception shown below. The form panel with the toggle has not been displayed when the setValue() was called.

    Call stack:

    Uncaught TypeError: Cannot read property 'offsetBoundary' of undefined
    Ext.form.Slider.Ext.extend.getPixelValue sencha-touch-debug.js:27341
    Ext.form.Slider.Ext.extend.setValue sencha-touch-debug.js:27286
    Ext.form.Toggle.Ext.extend.setValue sencha-touch-debug.js:27517
    Views.DalTestView.Ext.extend.TableChanged DalTestView.js:267

    Regards,
    Vlad.

  2. #2
    Sencha User
    Join Date
    Aug 2010
    Posts
    19
    Vote Rating
    0
    maertsch is on a distinguished road

      0  

    Default


    If got a Toggle field:
    new Ext.form.Toggle({
    name:'sts',
    id:'sts',
    required:false,
    label:'STS'
    }),

    and get the following error:
    Uncaught TypeError: Cannot read property 'offsetBoundary' of undefined
    Ext.form.Slider.Ext.extend.getPixelValuesencha-touch-debug.js:27341
    Ext.form.Slider.Ext.extend.setValuesencha-touch-debug.js:27286
    Ext.form.Toggle.Ext.extend.setValuesencha-touch-debug.js:27517
    Ext.form.FormPanel.Ext.extend.setValuessencha-touch-debug.js:26666
    Ext.form.FormPanel.Ext.extend.loadRecordsencha-touch-debug.js:26605
    Ext.form.FormPanel.Ext.extend.loadModelsencha-touch-debug.js:26616
    webApp.views.ReservationDetail.Ext.extend.initReservationReservationDetail.js:150
    Ext.apply.items.reservationList.Ext.List.listeners.itemtapReservations.js:36
    firesencha-touch-debug.js:979
    Ext.util.Observable.Ext.extend.fireEventsencha-touch-debug.js:595
    Ext.DataView.override.onTapsencha-touch-debug.js:23082
    anonymous:5
    (anonymous function)sencha-touch-debug.js:4428
    Ext.gesture.Gesture.Ext.extend.firesencha-touch-debug.js:18588
    Ext.gesture.Tap.Ext.extend.onTouchEndsencha-touch-debug.js:18781
    Ext.gesture.Manager.Ext.AbstractManager.onTouchEndsencha-touch-debug.js:18282
    (anonymous function)sencha-touch-debug.js:3421

    it doesn't even render.
    Tested on Chrome 11Beta ST 1.1.0

    regards

  3. #3
    Sencha User
    Join Date
    Jun 2010
    Posts
    66
    Vote Rating
    0
    dontbugme is on a distinguished road

      0  

    Default


    *bump*

    Having the same problem.
    Is there any workaround?

  4. #4
    Sencha User
    Join Date
    Aug 2010
    Posts
    19
    Vote Rating
    0
    maertsch is on a distinguished road

      0  

    Default


    haven't found one. i switched to a checkbox...

    I've found an unofficial deploy of ST, say 1.2.0 beta, there it works good.
    I guess that a final release of that version should be official in some days/weeks. Otherwise you could get a SVN-Access and download the latest.

    regards

  5. #5
    Sencha User mobileme's Avatar
    Join Date
    Dec 2010
    Posts
    20
    Vote Rating
    0
    mobileme is on a distinguished road

      0  

    Default


    The same to me with ToggleField on ST 1.1
    While try to binding data to form, I got this odd error on toggle field: Cannot read property 'offsetBoundary' of undefined

  6. #6
    Sencha User
    Join Date
    May 2012
    Posts
    4
    Vote Rating
    0
    saranya sukumar is on a distinguished road

      0  

    Default


    Hi ,
    I experienced the same error too in my application. I just gave like this and it solved my problem.

    Code:
    var aa=Ext.getCmp('togglefield id');
    aa.value=1;
    Thanks,
    Saranya

Similar Threads

  1. [FIXED-522] toggle.setValue() doesn't properly update UI slider
    By iffius in forum Sencha Touch 1.x: Bugs
    Replies: 4
    Last Post: 13 Aug 2014, 6:21 AM
  2. Ext.form.Toggle - setValue issue
    By mathos in forum Sencha Touch 1.x: Discussion
    Replies: 6
    Last Post: 29 Feb 2012, 2:40 PM
  3. [OPEN-741] Ext.form.Toggle setValue()
    By maertsch in forum Sencha Touch 1.x: Bugs
    Replies: 1
    Last Post: 2 Feb 2011, 5:18 AM
  4. Toggle component's setValue & toggle functions give an error
    By ncanton in forum Sencha Touch 1.x: Discussion
    Replies: 0
    Last Post: 28 Oct 2010, 10:35 PM
  5. Toggle.setValue() and NestedList.Add() Problems
    By SuperTron in forum Sencha Touch 1.x: Discussion
    Replies: 1
    Last Post: 30 Jul 2010, 9:51 PM

Thread Participants: 4

Tags for this Thread