nathon py wrote:
> #  Let's say a window with title 'D:\\labBufferSpace' exists.
> #  Code below does not work in DOS, or just double it.
> #  But it works well in  PythonWin.
> #  I do not want to run it in PythonWin every time.
> #  I take it as a bug, and reported it to sourceforge.net
> <http://sourceforge.net>, did I do that wrong?
> ########################################################
> import win32ui,win32con,pythoncom,win32gui,win32process,win32api
> pwin = win32gui.FindWindow(0,'D:\\labBufferSpace')
> win32gui.BringWindowToTop(pwin) 

If it is a bug, it is a bug in the Win32 API.  This same code also does
not work in a console app written in C.

Use SetForegroundWindow instead of BringWindowToTop.  That works.

-- 
Tim Roberts, t...@probo.com
Providenza & Boekelheide, Inc.

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

Reply via email to