Rif: Re: How To Do It Faster?!?

Peter Hansen peter at engcorp.com
Thu Mar 31 10:58:48 EST 2005


andrea.gavana at agip.it wrote:
> Unfortunately, on Windows it does not seem to work very well:
>>>>st = os.stat('MyFile.txt')
>>>>print st.st_uid
> 0
> 
> I don't think my user ID is 0...
> 
> While with the OS dos command I get:
> 
> userid: \\ENI\ag12905

I would recommend using the pywin32 support that almost
certainly exists for getting the owner of a file.

On the other hand, I'm not familiar with the Windows
API in question, but either somebody else will point
you to it, or a search on msdn.com would find it for
you.

-Peter



More information about the Python-list mailing list