1 Reply Latest reply on Apr 18, 2008 9:16 AM by Admiral_Brodnack

    createRootWindow Error

    WhyIsEveryNameTaken?
      i cannot seem to get air.HTMLLoader.createRootWindow to actually work without giving me some sort of error...mostly seme TypeError: Undefined value error. what am i doing wrong. how come this code doesnt work?
      function makeReal()
      {
      var init = new air.NativeWindowInitOptions();
      var bounds = null;
      var win = null;
      var login = air.File.applicationDirectory.resolvePath( 'login.html' );
      bounds = new air.Rectangle( ( air.Capabilities.screenResolutionX - 325 ) / 2,
      ( air.Capabilities.screenResolutionY - 145 ) / 2, 325, 145 );
      init.minimizable = false;
      init.maximizable = false;
      init.resizable = false;

      win = air.HTMLLoader.createRootWindow( true, init, false, bounds );
      win.load( new air.URLRequest( login.url ) );
      }

      TypeError: Undefined value
      makeReal at app:/telya.html : 21