Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7278257
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T22:51:00+00:00 2026-05-28T22:51:00+00:00

How determine if mouse points to(hover on) maximise button of window even if this

  • 0

How determine if mouse points to(hover on) maximise button of window even if this window is not of my application.
Is there API for that ?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-28T22:51:01+00:00Added an answer on May 28, 2026 at 10:51 pm

    You may send a WM_NCHITTEST to that window. The return value will correspond to the object type on the requested coordinates.

    Something like this:

    bool IsMouseOverMaxBtn(HWND hWnd)
    {
        POINT pt;
        VERIFY(GetCursorPos(&pt)); // get mouse position
    
        int retVal = SendMessage(hWnd, WM_NCHITTEST, 0, MAKELONG(pt.x, pt.y));
    
        return HTMAXBUTTON == retVal;
    }
    

    Edit:

    You may send this message to any window (not necessarily belong to your thread/process). Since no pointers are involved (such as string pointers) – there’s no problem.

    However you should note that sending (not posting) a message to a window belonging to another thread is a pretty heavy operation, during which your thread is suspended. There may even happen a situation where your thread hangs, because the thread of the application that serves that window hangs.

    You may consider using SendMessageTimeout to guarantee your thread won’t hang.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Is there a Win32 API call to determine what window and/or control is visible
Is there any way to determine if the mouse scrolls up or down using
I would like to write a program that will determine whether the mouse is
This may seem like a silly question, but is there some way to determine
is there a way how to determine if the current mouse cursor is animated
Is there a way in JFreeChart to determine from a ChartMouseEvent that x,y coordinates
Problem: Determine which radio button was sent based on their order and submit the
I am trying to determine if a phone is located in this polygon using
Is there a way to determine the size and position of the visible area
Background: I have a function in my program that takes a set of points

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.