开发者

SendMessage(focused, WM_GETTEXT, builder.Capacity, builder); returns empty string

I am using the code described in Get active window text (and send more text to 开发者_C百科it) and it has problems retrieving the text from facebook chat or from messenger chat or from textboxes inside websites - it returns an empty string.

Do you have any idea what's the problem and how can I overcome it?


This method works only for standard controls that windows implements. Home-brew ones doesn't have to obey this message. For example, all the controls in Mozilla browsers are not windows originated (probably due to the cross-platform nature of the browser). So probably the only browsers that uses standard controls is IE (I'm still not sure since the ie team could go its separate way for performance reasons)

As for universal method, I don't know whether there exists one. Opera, IE, FireFox, Chrome all use different code bases.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜