# Resolution Detector/Center Pop-Up Problem

**URL:** <https://forum.kirupa.com/t/resolution-detector-center-pop-up-problem/163826>\
**Category:** flash\
**Created:** [September 26, 2005, 3:36pm UTC](https://forum.kirupa.com/t/resolution-detector-center-pop-up-problem/163826 "2005-09-26T15:36:37Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![bleedmedia](https://avatars.discourse-cdn.com/v4/letter/b/bcef8e/32.png) [@bleedmedia](https://forum.kirupa.com/u/bleedmedia)\
**Post date:** [September 26, 2005, 3:36pm UTC](https://forum.kirupa.com/t/resolution-detector-center-pop-up-problem/163826/1 "2005-09-26T15:36:37Z")

</div>

Hello,

I have a resolution detector on my site that will launch a different pop-up window depending on the user’s screen resolution. I would also like for the pop-up window to center its self. I’ve already looked at the following tutorial: [http://www.kirupa.com/developer/mx/centered\_popup.htm](http://www.kirupa.com/developer/mx/centered_popup.htm), but I didn’t have any luck adding these actions to the actions I already have in place. Does anybody have any solutions for making these pop-up windows center themselves?

My FLA is too large to attach, but below are my actions, and you can view a test version of the site here: [http://www.bleedmedia.com/site\_test/](http://www.bleedmedia.com/site_test/) If you need any other information please let me know. Thanks

The following are my actions for the resolution detector:

stop();  
trace(System.capabilities.screenResolutionX+" : "+System.capabilities.screenResolutionY);  
if (System.capabilities.screenResolutionY\<768) {  
gotoAndStop(“small”);  
} else if (System.capabilities.screenResolutionY == 768) {  
gotoAndStop(“medium”);  
} else if (System.capabilities.screenResolutionY\>=1024) {  
gotoAndStop(“large”);  
} else {  
gotoAndStop(“medium”);  
}

And here are my actions for the pop-ups:

getURL(“javascript:spawnWindow(‘large/base.html’,‘Bleed’,‘toolbar=no,location=no,status=no,menubar=no,scrollbars=no,resizable=no,width=1272,height=976’)”);  
stop();

Any solutions or ideas would be very much appreciated. Thanks a lot!
