Help for this page

Select Code to Download


  1. or download this
    C:\test>junk44
    Permission denied : The process cannot access the file because it is b
    +eing used by another process at C:\test\junk44.pl line 30.
    perl.exe pid: 17320 PB-IM2525-AIO\HomeAdmin :    60: File  (RW-)   C:\
    +test\ttz
    cmd.exe pid: 17324 PB-IM2525-AIO\HomeAdmin :    60: File  (RW-)   C:\t
    +est\ttz
    handle.exe pid: 16152 PB-IM2525-AIO\HomeAdmin :    60: File  (RW-)   C
    +:\test\ttz
    
  2. or download this
    cmd.exe /x/d/c "cmd /c echo xx >$file"
    
  3. or download this
    use strict;
    use warnings;
    ...
    if( !unlink($file) ) {
        warn $!, ' : ', $^E;
    }
    
  4. or download this
    ## In a different session from which I will run my modified version of
    + your script
    C:\test>echo xx > ttz
    ...
    ## And back in the first session whilst the 10 second sleep is running
    C:\test>handle | find "ttz"
       60: File  (RW-)   C:\test\ttz