Becky Mcquilling wrote:
I'm new to Python and wanted to do what is a pretty routine and common admin
function, simple enough in VBScript, but wanted to try it in Python as
well. I'm having troulbe working it out on my own.
Welcome to Python!
I have a text file c:\servernames.txt. I want
Dear list,
I wrote a small class which has some COM objects among its attributes. I
need to access the object from different threads so I defined two methods to
marshal and unmarshal the interfaces when working with the object.
Everything seemed to work fine on my PC, never had an error.
But I
On Feb 20, 2008 3:04 AM, Tim Golden [EMAIL PROTECTED] wrote:
Becky Mcquilling wrote:
I'm new to Python and wanted to do what is a pretty routine and common
admin
function, simple enough in VBScript, but wanted to try it in Python as
well. I'm having troulbe working it out on my own.
I cant see how this class is used, but it is slightly suspect, in the fact
it stores the result of the unmarshal in self.fmProject but there is
nothing to prevent other threads from using self.fmProject, which would be
an error. Unless something not shown prevents this happening, you need to
Thanks! Another question, related and random. Someone, anyone?
I am trying to implement an MSMQ, and I have no idea whats going wrong. I
looked at:
http://comsci.liu.edu/~murali/python/python28.txt
one of the few places that actually has help with that. I tried to implement it
but for some
code - untested
import wmi
servers = open (c:/servernames.txt).read ().splitlines ()
for server in servers:
wmi_connection = wmi.WMI (server)
with open (%s-services.log % server, w) as f:
for service in wmi_connection.Win32_Service ():
f.write (%s\t%s\n %
If I am not mistaken, you can use the with statement with python 2.4
from __future__ import with_statement
Um, forget that. That is 2.5 like you said. Sorry.
Don't have 2.4 installed anymore to test my brain farts before sending them
on.
*Jedi mind trick* You never saw this mail