> Amit Arora wrote:
> Hi, 
> 
> I am a Amateur in python and an doing some work on Python and Win32 APIs.
> 
> One of my task includes finding the active window , during any
> installation proces and proceed ......
> Take an instance : I connect a USB device say a USB printer to the USB
> port , as soon as it connects we get a pop-up saying "New Hardware Found" 
> 
> I need to detect that popup , and then proceed with the other
> installation steps if that popup occurs :
> 
> Trying to check its appearance with the following command : 
> 
> #!/usr/local/bin/python
> Import os , win32gui, win32ui 
> 
> hWnd = win32ui.FindWindowEx(win32gui.GetDesktopWindow(), None,
> "wndclass_desked_gsk",None)
> 
> Getting the following message : 
> Traceback (most recent call last):
>   File "<interactive input>", line 1, in <module>
> win32ui: No window can be found.

A couple things to check:
Are you sure the window class name is correct ?
Is the desktop window actually its parent ?

   hth
       Roger

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

Reply via email to