Information générale
Catégorie:
Codage, syntaxe et commandes
Hi Jim --
>>This doesn't work because the selected text could be on any form and any control.<<
Are you comfortable with APIs? The typical way to do this would be to use GetFocus or GetForegroundWindow to obtain the hWnd of the active textbox. Then call SendMessage with EM_GETSEL. On return, wParam will hold the starting position, and lParam the ending position, of the selected text. If these values are equal, no text is selected.
Later... Karl
Précédent
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement