Api pour recuperé texte sous la souris

Signaler
Messages postés
5
Date d'inscription
jeudi 1 juin 2006
Statut
Membre
Dernière intervention
19 septembre 2006
-
Messages postés
17288
Date d'inscription
mercredi 2 janvier 2002
Statut
Modérateur
Dernière intervention
27 septembre 2021
-
salut à tous, bon je cherche un api pour recuperé le texte sous la souris (lorsque je place la souris sur un controle de windows comme un icon du bureau je veut recuperé le texte sous la souris càd nom de ce dossier)

si quelqu'un sait utilisé l'api ;GetRolText je demande d'aide

merci pour tous

2 réponses

Messages postés
2237
Date d'inscription
lundi 29 mai 2006
Statut
Membre
Dernière intervention
29 mai 2008
10
Salut, tiens voilà quelque API pour gérer la souris, vois si ça peut t'aider, sinon dans donne toute la fonction GetRolText pour voir à quoi ça ressemble!

Declare Function ClientToScreen Lib "user32" Alias "ClientToScreen" (ByVal hwnd As Long, lpPoint As POINTAPI) As Long
The ClientToScreen function converts the client coordinates of a specified point to screen coordinates.

Declare Function ClipCursor Lib "user32" Alias "ClipCursor" (lpRect As Any) As Long
The ClipCursor function confines the cursor to a rectangular area on the screen.



Declare Function GetCursorPos Lib "user32" Alias "GetCursorPos" (lpPoint As POINTAPI) As Long
The GetCursorPos function retrieves the cursor?s position, in screen coordinates.



Declare Function GetDoubleClickTime Lib "user32" Alias "GetDoubleClickTime" () As Long

The GetDoubleClickTime function retrieves the current double-click time for the mouse. A double-click is a series of two clicks of the mouse button, the second occurring within a specified time after the first. The double-click time is the maximum number of milliseconds that may occur between the first and second click of a double-click.



Declare Sub mouse_event Lib "user32" Alias "mouse_event" (ByVal dwFlags As Long, ByVal dx As Long, ByVal dy As Long, ByVal cButtons As Long, ByVal dwExtraInfo As Long)
The mouse_event function synthesizes mouse motion and button clicks.Windows NT only: This function has been superseded. Use MouseEventEx instead.

Declare Function SetCursorPos Lib "user32" Alias "SetCursorPos" (ByVal x As Long, ByVal y As Long) As Long
The SetCursorPos function moves the cursor to the specified screen coordinates. If the new coordinates are not within the screen rectangle set by the most recent ClipCursor function, Windows automatically adjusts the coordinates so that the cursor stays within the rectangle.

Declare Function SetDoubleClickTime Lib "user32" Alias "SetDoubleClickTime" (ByVal wCount As Long) As Long
The SetDoubleClickTime function sets the double-click time for the mouse. A double-click is a series of two clicks of a mouse button, the second occurring within a specified time after the first. The double-click time is the maximum number of milliseconds that may occur between the first and second clicks of a double-click.

Declare Function ShowCursor Lib "user32" Alias "ShowCursor" (ByVal bShow As Long) As Long
The ShowCursor function displays or hides the cursor.

Declare Function SwapMouseButton Lib "user32" Alias "SwapMouseButton" (ByVal bSwap As Long) As Long
The SwapMouseButton function reverses or restores the meaning of the left and right mouse buttons.

 Drikce 06
Messages postés
17288
Date d'inscription
mercredi 2 janvier 2002
Statut
Modérateur
Dernière intervention
27 septembre 2021
70
tu veux cette info, sur TOUT ce qui est ecrit, partout ?

où juste sur un TextBox, etc...?

Renfield
Admin CodeS-SourceS- MVP Visual Basic