[API ] SendMessage 怪問題

看板Visual_Basic作者 (莎里奈)時間17年前 (2008/07/25 01:02), 編輯推噓1(104)
留言5則, 4人參與, 最新討論串1/1
Private Declare Function SendMessage Lib "user32" Alias "SendMessageA" ( ByVal hWnd As Long, ByVal wMsg As Long, ByVal wParam As Long, ByVal lParam As String ) As Long 說明 hWnd Handle to the window whose window procedure will receive the message Msg [in] Specifies the message to be sent. wParam [in] Specifies additional message-specific information. lParam [in] Specifies additional message-specific information. ----------------------------------------------- 說明 S為空字串 (1) SendMessage handle_x , WM_GETTEXT , S , Len(S) Text1.Text = S 結果:Text1.text仍是空字串 ------------------------------------------ 改為 (2) SendMessage handle_x , WM_GETTEXT , Len(S) , S Text1.Text = S 結果:Text1.text抓到我要的內容 怎麼會這樣,是差在哪? -- ※ 發信站: 批踢踢實業坊(ptt.cc) ◆ From: 218.160.248.200 ※ 編輯: saininniang 來自: 218.160.245.109 (07/25 02:09)

07/25 02:10, , 1F
請查MSDN, WM_GETTEXT
07/25 02:10, 1F

07/25 03:21, , 2F
原來如此,我終於了解了,感謝
07/25 03:21, 2F

07/25 03:21, , 3F
為什麼大家那麼強,我那麼弱
07/25 03:21, 3F

07/25 19:30, , 4F
多翻文件 就會進步
07/25 19:30, 4F

07/28 14:38, , 5F
好奇怪的問題 @@>
07/28 14:38, 5F
文章代碼(AID): #18YBMl8C (Visual_Basic)