Results 1 to 3 of 3

Thread: How to save form values to store

  1. #1
    Sencha User
    Join Date
    Apr 2012
    Posts
    12
    Vote Rating
    0
      0  

    Default How to save form values to store

    Hi,

    I have a form panel with some text fields and a button. I want to submit my form values to the local store when user clicks on the button. I was wondering if someone can tell me steps to achieve this then that would be great.

    I would appreciate any help.
    Thanks in advance!
    Sonal

  2. #2
    Sencha User aconran's Avatar
    Join Date
    Mar 2007
    Posts
    9,487
    Vote Rating
    145
      0  

    Default

    Assuming you have a reference within the form and you have access to the store...

    Code:
    var values = this.getValues();
    store.add(values)
    Aaron Conran
    @aconran

  3. #3
    Sencha User
    Join Date
    Apr 2012
    Posts
    12
    Vote Rating
    0
      0  

    Default

    Thanks for the response. I am getting following error: Object [object Object] has no method 'getValues'

    Also I am new to sencha framework and this is my first form. I am not sure if I should use button handler or controller. If you can provide more details then that would be great.

    Thanks,
    Sonal

Posting Permissions

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