GetWindowText cannot retrieve the text of a control in another application.
我想retrieve the text of a control in another application该如何做呢?

解决方案 »

  1.   

    发消息 ::SendMessage()WM_GETTEXTSee Also
    DefWindowProc, GetWindowText, GetWindowTextLength, LB_GETTEXT, WM_GETTEXTLENGTH, WM_SETTEXTRequirements 
    Runs on Versions Defined in Include Link to 
    Windows CE OS 1.0 and later Winuser.h     
    This message is sent by an application to copy the text that corresponds to a window into a buffer provided by the caller. WM_GETTEXT wParam = (WPARAM) cchTextMax; 
    lParam = (LPARAM) lpszText;
    ============================================================================
    提问题时标题要简明扼要地说明问题内容,切忌使用"急","求救"之类不能说明问题的标题
    http://www.betajin.com/alphasun/index.htm          给我发信息请附带原帖地址
    http://alphasun.18en.com/                    http://shakingtoolkit.9126.com/
    DocWizard C++程序文档自动生成工具 | Wave OpenGL | HttpProxy | AjaxParser词法分析
      

  2.   

    《Windows核心编程》刚刚好有这个问题的一模一样的描述和解决办法。用线程插入技术。还是去看书吧。三言两语说不清楚的。
      

  3.   

    对于基本控件可以发送WM_GETTEXT消息,对于是通用控件可能有点麻烦,看《核心编程》
      

  4.   

    ToolHelp还能做这个?其实说到底你这个程序就像查看“*”密码的程序一样。
    发WM_GETTEXT消息