Results 1 to 2 of 2

Thread: Sencha touch MVC -reference error

    Thank you for reporting this bug. We will make it our priority to review this report.
  1. #1

    Exclamation Sencha touch MVC -reference error

    Hi I am new to Sench touch,
    I tried to develop the MVC application given in following tutorial,
    http://miamicoder.com/2011/writing-a...c-application/

    I followed the same folder structure.
    But when i run the application I am getting
    Reference error:Can't find variable NotesApp

    One of the file containing this error is shown below,
    NotesApp.views.MainView=Ext.extend(Ext.Panel,{
    fullscreen:true,
    layout:'card',
    cardSwitchAnimation:'flip',
    initComponent:function(){
    Ext.apply(NotesApp.views, {
    notesListView:new NotesApp.views.NotesListView({
    notesStore:NotesApp.stores.notesStore
    }),
    notesEditorView:new NotesApp.views.NotesEditorView()
    });
    this.items=[
    NotesApp.views.notesListView,
    NotesApp.views.notesEditorView
    ]
    NotesApp.views.MainView.superclass.initComponent.call(this);
    this.on('render',function(){
    NotesApp.stores.notesStore.load();
    });
    }
    });


    I do not understand the cause of this error. Please help!!!!

  2. #2
    Sencha User Sameer Khan's Avatar
    Join Date
    Oct 2011
    Location
    Bangalore, India
    Posts
    118

    Default

    on() should be called with in the constructor. Not out side of constructor...Plz refer Api once...you will get Idea. where to use.
    Sameer Khan

Posting Permissions

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