Results 1 to 2 of 2

Thread: getValues is not defined

  1. #1
    Sencha User
    Join Date
    Jul 2018
    Posts
    11

    Default getValues is not defined

    Ext Js version modern 6.2
    An error appears in the console: form.getValues is not a function
    Is the form well positioned: form = me.dialog.down ('fieldset')

    //FeedForm.js

    Ext.define('FeedViewer.view.main.FeedForm',{
    extend:'Ext.form.Panel',
    xtype:'feedform',

    requires:[
    'Ext.Button',
    'Ext.field.Select',
    'Ext.form.FieldSet',
    'Ext.Toolbar'
    ],

    title:'New RSS Feed',

    items:[{
    xtype:'fieldset',
    items:[
    {
    xtype:'textfield',
    label:'Select a new feed',
    labelAlign:'top',
    allowBlank:false,
    name:'feedUrl'
    }
    ]
    },{
    xtype:'toolbar',
    docked:'bottom',
    items:[{
    xtype:'button',
    reference:'savebutton',
    action:'save',
    ui:'action',
    text:'Add'
    }]
    }]
    });


    //MainController.js



    onSave: function(button, e, options){
    var me = this,
    form = me.dialog.down('fieldset'), //Is the form well setting?
    values = form.getValues() //Console error: form.getValues is not a function
    }

  2. #2

    Default

    add a 'reference' config in this form
    then in your onSave function,
    you should use : this.lookup('your reference').getForm().getValues()

Similar Threads

  1. how to use getValues in formPanel?
    By kazz in forum Q&A
    Replies: 2
    Last Post: 25 Jul 2017, 8:15 AM
  2. Replies: 1
    Last Post: 29 Nov 2011, 5:53 AM

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
  •