Thanks TH. That's weird, there must be something else in my code, then as I'm still not able to get it to the center. My hierarchy in my main.mxml is mx.Application > mainPanel > myPopupButton
I tried this.parent as Sprite and mainPanel.parent as Sprite And a couple of other things.. TH, I'm not waiting on a solution from you specifically, because you were just explaining the facts about the popup specifically, and the need to cast that parameter. Maybe someone else will see this who has run into this specific situation. Steve --- In [email protected], "turbo_vb" <timh...@...> wrote: > > Hi Steve, > Popups exist outside the normal DisplayList, so you can work around it > by setting the Alert's parent like this: > Alert.show("your text", "your title", 4, parentApplication as Sprite); > -TH > --- In [email protected], "steveb805" > wrote: > > > > Seems like until now, my Alert boxes appear in the center ok. > > > > However, now that I am using a PopUpButton, and in response to one of > the menu item clicks I am calling Alert.show(), the popup box is stuck > at the upper left. > > > > My popupbutton handler: > > > > private function itemClickHandler(event:MenuEvent):void { > > switch (event.index) { > > case 0: > > ... > > case 1: > > Alert.show( "Are you sure? \n\n There is no Un-Do", > > 'Delete *All Completed* ?', > > Alert.YES| Alert.NO, > > null, > > responseToDeleteAllCompletedHandler, > > null, > > Alert.NO); > > default: > > } > > } > > > > > > For the parent parameter - which is supposed to be a Sprite - I tried > this.parent, hoping this would fix it, but complained of type mismatch. > > > > Weird that the Alert works fine when calling it in response to normal > buttons on my main panel, but all of a sudden the Alert is confused > about the parent when calling the Alert.show in response to a *popup* > type button. > > > > ( maybe I should download an updated Flex sdk? it's been a couple of > months) > > > > Any advice would help > > tx, > > Steve > > >

