I need to fabricate a "file in use" scenario. I am programming exception handling for this particular scenario but I am unable to come up with a way to put a file "in use" so other programs are unable to delete or modify it.
Is there a simple way to do this that I'm overlooking?