PDA

View Full Version : How to positioned a window?



Avalon
1 Dec 2009, 4:54 AM
Hi all,
how can i positioned my window 200px from screen top and center it?

var win = new Ext.Window({
...
});

Something like this pseudo code: win.setPosition(200, screen.width / 2);

Thanx
Avalon

DynamoEffects
1 Dec 2009, 4:59 AM
Set the y property:
http://www.extjs.com/deploy/dev/docs/?class=Ext.Window&member=y

Avalon
1 Dec 2009, 5:48 AM
Hi DynamoEffects,
your right :) If i set only the y attribute, ExtJS centers the x coordinate.