6 replies
by mckaytech
If you know the file ID, you can use "net file [id] /close". I haven't figured out yet how you get a list of the open file IDs so I know this isn't the whole answer but maybe it will give you a starting point.
paul
by lbabson
Thanks. This did give me a start. I have to send the output of the net file command to a file. Use grep to search the file for the files I'm concerned about, extract the file ids, then use net file id /close. -A pain, but so far it's the only way.
Thanks again.
by _degan_
I'll be interested if someone has a direct answer to this question.
If you need to do this repeatedly, and the resource is an application, you can use the resource kit an make the application run as a service. Then you can easily use an NET START and STOP to control it.
by lbabson
by wayne.maples
The Windows NT Resource Kit includes Tlist.exe and PUList.exe which lists active tasks and processes and gives the pid . Combined with the kill command, you could do this.
-Wayne
by lbabson
This discussion is closed to new replies.
Trending Windows Forum posts
Sort by Trending