>> I believe that "uptime" works from the console, but don't have a machine
>> to check it with...
> Doesn't work for me, but if you have win32all installed, you can get it
> from Python:
> >>> import win32api
> >>> print "Uptime:", win32api.GetTickCount(), "Milliseconds"
> Uptime: 148699875 Milli
[Peter Hanson]
> The real solution, in spite of the dozen alternatives we've
> now produced, seems to be to use the win32pdh library
> to access the "System"-> "System Up Time" value. It
> claims to return an 8-byte value, which likely doesn't
> wrap quite so soon. (And yes, remarkably, with the
>> Writting this script was harder than I initially thought due to
>> a lack of documentation for win32all. And I still don't know what
>> that bizzare_int value stands for (an error/status code?).
[Fredrik Lundh]
> if I'm not mistaken, the corresponding Win32 function is called
> PdhGetFormattedC
[phil]
> I need to know if a process is running.
> not just python.exe
> but python.exe myapp
> from win32all
> EnumProcesses gives me the pids, then
> OpenProcess(pid) gives me a handle.
> Then what?
> GetModuleFileNameEX?
It won't do the right thing for you. As far as I know,
G
[Read Roberts]
> I wrote my own directory browser in order to get around a bug where
> tkFileDialog.askdirectory() can't handle non-ascii paths. However, I
> have a problem where I call os.listdir() on a mapped network drive,
> e.g. os.listdir("Z:\\"), and if the network drive is unavailable, th