PostMessage_UDF.au3 怎么实现发送中文
PostMessage_UDF里有一个_SendText 函数 发送不了中文 高手帮改下_SendText 函数如下
Func _SendText($hWnd, $str)
If $hWnd = 0 Or StringLen($str) = 0 Then
SetError(-1)
Return
EndIf
Local $user32 = DllOpen("user32.dll")
For $i = 1 To StringLen($str)
DllCall($user32, "int", "PostMessage", "hwnd", $hWnd, "int", 0x102, "int", Asc(StringMid($str, $i, 1)), "long", 0)
Next
If $user32 <> -1 Then DllClose($user32)
EndFunc
页:
[1]