You probably should use special function described in Win32-SDK help files.
Most probably function in interest is DeviceIoControl. I see some words about locking a volume here, like FSCTL_LOCK_VOLUME.
You can use those functions via Win32::API module.
Best wishes,
Vadim.
Comment on Re: Perventing eject of zip disk on windows
Replies are listed 'Best First'.
A reply falls below the community's threshold of quality. You may see it by logging in.