Get Window X and Y?

This is a discussion on Get Window X and Y? within the Windows Programming forums, part of the Platform Specific Boards category; There is some function wich return the X and Y position of an button, edit, or any other control? Thanks...

  1. #1
    Registered User
    Join Date
    Sep 2006
    Posts
    57

    Get Window X and Y?

    There is some function wich return the X and Y position of an button, edit, or any other control? Thanks

  2. #2
    Software Developer jverkoey's Avatar
    Join Date
    Feb 2003
    Location
    University of Waterloo
    Posts
    1,904
    If you have the handle to the window, use GetWindowRect. This fills a RECT structure with the coordinates of the window relative to the top left corner of the screen.

Popular pages Recent additions subscribe to a feed

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21