RSS category feeds

RSS site feeds

Home
Show the path of all Explorer Windows Print E-mail
The Python/Pywin32 Script collection - Microsoft Windows

This piece of Python code shows the current path of all opened Explorer Windows

 
from win32com.client.gencache import EnsureDispatch
 
for w in EnsureDispatch("Shell.Application").Windows():
    print w.LocationName + "=" + w.LocationURL
Last Updated ( Wednesday, 30 January 2013 )
 
Simple VBA like MessageBox in Python Print E-mail
Newsflash - Newsflash

ImageSome days ago I found a very easy pythonic way to show a VBA-like MessageBox. It was created with only one line of cpython code.

The code is very very easy:

 
import ctypes
 
msgbox = ctypes.windll.user32.MessageBoxA
ret = msgbox(None, 'Press OK to end the demo.', 'Deviare Python Demo', 0)
print ret
Last Updated ( Tuesday, 08 January 2013 )
 
PathWatcher.py keeps an eye on any changes in any directory Print E-mail
The Python/Pywin32 Script collection - Microsoft Windows
This little script runs only on windows and watches at low level into a givven directory. If any changes occur, it will immidiatly show you what has changed. I use it regularly to watch into a directory (works also with UNC pathes and samba) and follow, which files were modified. It watches into the complete directory tree with sub directories. Very simple, use it like this:
 
python.exe c:\temp\PathWatcher.py \\SRVXY\released_docs
Last Updated ( Thursday, 11 October 2012 )
 
<< Start < Prev 1 2 3 4 5 6 Next > End >>

Results 1 - 8 of 43

Feedback

Suggested

Comments

  • It works great for me. Im running W8 Enterprise and Pro with Pyth 2.7. Thanks fo... More...
  • I tried it without attachment and everythign works. What i dont understand is th... More...
  • Ok, the script was wrong. The last patrameter for the type 7 is wrong. I have co... More...
  • in windows 8, it just prints 0... tried in Python 3.3 and ActivePython 2.7 More...
  • Hi Brent, I am new to the catia customization using python. I am facing the same... More...

Login Form






Lost Password?

Exits

My prefered Python IDE

My prefered Python editor is Pyscripter from MMExperts. It is not only an editor. Pyscripter is a full Python IDE including (remote) debugging, a class browser, and all other nice helpers which a full featured IDE needs.

Do you have a script for me ?

Do you have an interesting Python script which does some really cool thing on Windows ? Please post them to this site. It`s very simple - simply copy&paste it to this form. No login is requiered.

Hint: For syntax highlighting and correct Python intendation place your code between html tags <pre> and </pre>.

My prefered web framework

My prefered web framework for developing web applications is Django. Django calls itself The web framework for perfectionists with deadlines. It is a really fast, scalable and (thanks Python) the sexiest web framework of the world.