Results 1 to 2 of 2

Thread: Sencha 2.2.0 alpha: document.body does not exist at this point

  1. #1
    Sencha Premium Member
    Join Date
    Mar 2008
    Posts
    145
    Answers
    6
    Vote Rating
    2
      0  

    Default Sencha 2.2.0 alpha: document.body does not exist at this point

    Let me start off by saying that I am very glad Sencha will be supporting IE10 and Windows 8 / Phone 8!

    As soon as I heard about ST2.2 alpha, I downloaded it and have started porting my ST2 app to it using Visual Studio 2012. I am running my ST2.2 alpha app in the Visual Studio 2012 debugger which launches IE10 and attempts to display 'index.html'. When my "new Ext.application({ ... " code runs, it causes a long stack of function calls that end in a call to the 'getBody' function (see below) which throws the "[Ext.getBody] document.body does not exist at this point" Error.

    Am I doing something wrong here? Is this the right place to report ST 2.2 alpha bugs?

    Code:
        getBody: function() {
            if (!Ext.documentBodyElement) {
                if (!document.body) {
                    throw new Error("[Ext.getBody] document.body does not exist at this point");
                }
    
                Ext.documentBodyElement = Ext.get(document.body);
            }
    
            return Ext.documentBodyElement;
        },

  2. #2
    Sencha - Sr Software Engineer mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    39,556
    Answers
    3932
    Vote Rating
    1272
      0  

    Default

    You shouldn't have new Ext.application, just Ext.application. Also, 2.2.0 alpha shouldn't be used for any production code because you are going to run into issues, just be playing with the alpha build.
    Mitchell Simoens @LikelyMitch
    Sencha Inc, Senior Software Engineer
    ________________
    Learn BBCode and use it! Checkout the CODE tag!

    Check out my GitHub, lots of nice things for Ext JS and Sencha Touch
    https://github.com/mitchellsimoens

Posting Permissions

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