iPad doesn't know what a window object is??
I only have two lines of code in my app.js file and I get an error.
The standalone window example in the Kitchen Sink runs just fine in the iPad simulator but when I copy and run the same code my app it doesn't work.
Titanium 1.2.1,
iPhone SDK 3.2
// code
var win = Titanium.UI.currentWindow;
win.backgroundColor = 'pink';
// error
[ERROR] Script Error = Result of expression 'win' [null] is not an object. at app.js (line 2).
2 Answers
-
Accepted Answer
You need to create a window first.
-
thx damien. i knew it had to be an operator error ;) for some reason i was thinking i had a default current window on start up.