[Python.NET] scary fun (who needs SystemExit?)

Aaron Watters awatters at connotate.com
Thu Mar 25 10:39:36 EST 2004

Just fiddling around here:

Python 2.3.2 (#49, Oct  2 2003, 20:02:00) [MSC v.1200 32 bit (Intel)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> import CLR
>>> L = CLR.System.Diagnostics.Process.GetProcesses()
>>> for x in L:
...     if x.ProcessName == u"python":
...          x.Kill()

This is one of very many scary things that can be done very easily
using Python.Net.  (I haven't tried to see what happens if it attempts
to kill all the other processes before committing suicide...)

Too much rope?

Anyways, this is certainly a great way to fiddle around with the
Libraries.  thanks again.
  -- Aaron Watters
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.python.org/pipermail/pythondotnet/attachments/20040325/24455fb2/attachment.html

More information about the PythonDotNet mailing list