On Tue, 12 Apr 2005 15:07:26 -0400, Daniel F <[EMAIL PROTECTED]> wrote:



have you tried win32gui.GetWindowText(hwnd) ?

you may note that the msdn api reference specifies 3 arguments for
this function, but pywin32 takes only one, the hwnd. dont know why,
but it certainly makes the function much easier to use...


Because those are outputs of GetWindowText. For any API that returns a string, the Windows API will have you pass in a buffer and a buffer size. In Python, strings can vary in length, so there is no need to send a pre-allocated string. The Python Win32 wrapper conveniently creates the buffer for you, and passes the resulting string as a return from the function.


--
- Tim Roberts, [EMAIL PROTECTED]
 Providenza & Boekelheide, Inc.

_______________________________________________
Python-win32 mailing list
Python-win32@python.org
http://mail.python.org/mailman/listinfo/python-win32

Reply via email to