¡@

Home 

python Programming Glossary: win32file

Create NTFS junction point in Python

http://stackoverflow.com/questions/1143260/create-ntfs-junction-point-in-python

can use the previously stated method and to read use from win32file import from winioctlcon import FSCTL_GET_REPARSE_POINT __all__..

createNamedPipe in python

http://stackoverflow.com/questions/13319679/createnamedpipe-in-python

I have two python files namedpipe a.py import win32pipe win32file p win32pipe.CreateNamedPipe r' . pipe test_pipe' win32pipe.PIPE_ACCESS_DUPLEX.. 300 None win32pipe.ConnectNamedPipe p None data Hello Pipe win32file.WriteFile p data this pipe creates a namedpipe test_pipe and.. and writes the data into the pipe. b.py import win32pipe win32file import win32file fileHandle win32file.CreateFile . pipe test_pipe..

Symlinks on windows?

http://stackoverflow.com/questions/1447575/symlinks-on-windows

in Python you can use python win32 API modules e.g. import win32file win32file.CreateSymbolicLink fileSrc fileTarget 1 see http docs.activestate.com.. you can use python win32 API modules e.g. import win32file win32file.CreateSymbolicLink fileSrc fileTarget 1 see http docs.activestate.com.. 1 see http docs.activestate.com activepython 2.7 pywin32 win32file__CreateSymbolicLink_meth.html for more details if you do not..

What is the best way to open a file for exclusive access in Python?

http://stackoverflow.com/questions/186202/what-is-the-best-way-to-open-a-file-for-exclusive-access-in-python

which I assume you are by the paths you'll need to use the win32file module. Fortunately there is a portable implementation portalocker..

How do I change the file creation date of a Windows file from Python?

http://stackoverflow.com/questions/4996405/how-do-i-change-the-file-creation-date-of-a-windows-file-from-python

this question Yak shaving for the win. import pywintypes win32file win32con def changeFileCreationTime fname newtime wintime pywintypes.Time.. fname newtime wintime pywintypes.Time newtime winfile win32file.CreateFile fname win32con.GENERIC_WRITE win32con.FILE_SHARE_READ.. win32con.OPEN_EXISTING win32con.FILE_ATTRIBUTE_NORMAL None win32file.SetFileTime winfile wintime None None winfile.close share..

Python windows File Version attribute

http://stackoverflow.com/questions/580924/python-windows-file-version-attribute

attribute about eg. a dll. I payed attention to wmi and win32file modules as well without success. python windows file attributes..

Checking file attributes in python

http://stackoverflow.com/questions/659847/checking-file-attributes-in-python

have the archive bit on. Thanks # coding latin 1 import os win32file win32con from time import start clock ext '.txt' '.doc' def.. def fileattributeisset filename fileattr return bool win32file.GetFileAttributes filename fileattr for root dirs files in os.walk.. files if i 4 in ext print '...' root ' ' i end ' ' fattrs win32file.GetFileAttributes i if fattrs win32con.FILE_ATTRIBUTE_ARCHIVE..