[python-win32] Re: wmi + pythonservice : multithreading issues ->
pdh returns an error
Aloys Baillet
aloys at alamaison.fr
Tue Aug 17 11:24:28 CEST 2004
Thank you very much Cédric!
It worked indeed!
I will investigate more on this l10n thing...
But you saved my day!
Best regards,
--
Aloys Baillet
R&D @ La Maison
www.alamaison.fr
Cedric Delfosse wrote:
> Le mar 17/08/2004 à 11:05, Aloys Baillet a écrit :
>
>>Hello all,
>>
>>With some more searches, I discovered the win32pdhutil package, and I
>>tried the sample example given in the win32pdhutil.py file:
>><code>
>>import win32pdhutil
>>print win32pdhutil.GetPerformanceAttributes("Memory", "Available Bytes")
>></code>
>>
>
> I think you need to do it like that
>
> <code>
> import win32pdhutil
>
> memory = win32pdhutil.find_pdh_counter_localized_name("Memory")
> avail = win32pdhutil.find_pdh_counter_localized_name("Available Bytes")
>
> print win32pdhutil.GetPerformanceAttributes(memory, avail)
> </code>
>
> because of l10n.
>
> Regards,
>
More information about the Python-win32
mailing list