If you're using FlashBuilder, or an MXML file for a WindowedApplication, you can do it this way, in the initialization handler. This uses the initial dimensions of the application (defined in the application.xml file) read from the bounds of the nativeWindow.
[MXML file contents]
<s:WindowedApplication xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark"
xmlns:mx="library://ns.adobe.com/flex/mx"
xmlns:local="*"
initialize="windowedapplication1_initializeHandler(event)"
>
<fx:Script>
<![CDATA[
protected function windowedapplication1_initializeHandler(event:FlexEvent):void
{
var w:int = Capabilities.screenResolutionX;
var h:int = Capabilities.screenResolutionY;
nativeWindow.x = (w - nativeWindow.bounds.width)*0.5;
nativeWindow.y = (h - nativeWindow.bounds.height)*0.5;
}
]]>
</fx:Script>
</s:WindowedApplication>