file-io-permissions

Security permissions for folder in vista (using c# application)

Hi, I've written a code in winforms and added this code to a setup application. (That code is actually to create files in application directory) When I try to run the application in vista it is not working because the file creation permission. If I manually enable the permissions to application folder it is working fine. How can I assi...

safely lock a file then move? windows

I have a file and need to ensure it exist before inserting a row into the db. After i insert i need to use the PK as part of the filename and move it into another location. How do i check if it exist then lock it so it cant be deleted until i can insert into the db then proceed to move the file without it being deleted upon releasing th...