Sign in to follow this  
RidiculousX

How to center a window (Windows)?

Recommended Posts

So I've made a splash screen but it's not centered. I need to center it. I was thinking of using SetWindowPos() with the SWP_NOSIZE flag to change its position, but I need to know the current display resolution. If someone could point me to a way to find the resolution or maybe an easier way altogether, that would be great. I've searched the Platform SDK documentation and looked on MSDN and Googled this problem, but didn't come up with anything (maybe I just suck at constructing a good search queary). Thanks in advance.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this