You are here

exit app when drive is removed.

7 posts / 0 new
Last post
acefire
Offline
Last seen: 16 years 2 weeks ago
Joined: 2008-01-26 20:13
exit app when drive is removed.

wouldnt it be possible to make it so that it shuts down portable apps when the drive is removed? i have seen that it knows bec the avail. memory changes so why not shut? also the protable roboform (not portablapps) does exit itself when you take out the drive. so iguess it is possible

Aciago
Aciago's picture
Offline
Last seen: 6 months 4 days ago
Joined: 2007-01-24 14:23
you

should not eject your PDrive without stop it first...

Anyway, you can try ejectscript, search this forum for it...

Welcome to PApps.com and please, next time SEARCH before post.

If a packet hits a pocket on a socket on a port,
and the bus is interrupted as a very last resort,
and the address of the memory makes your floppy disk abort,
then the socket packet pocket has an error to report Biggrin

RMB Fixed
Offline
Last seen: 14 years 3 months ago
Joined: 2006-10-24 10:30
Here's the problem :

how do you properly shut down a program running from a drive
that has been removed ?

rab040ma
Offline
Last seen: 2 days 14 hours ago
Joined: 2007-08-27 13:35
U3 solved that problem by

U3 solved that problem by copying the files to APPDATA on the C: drive first before running them. That does seem to be about the only way to do it that allows for a graceful shutdown, other than something like making the program run entirely in RAM and be able to shut itself down.

The other part of the problem is data. If you pull the USB drive out while the computer is saving data, the drive and the data can be messed up pretty badly. And you never know when some write to the removable drive might happen. The only way to avoid that is to make sure the Safely Remove function has been completed.

MC

Aciago
Aciago's picture
Offline
Last seen: 6 months 4 days ago
Joined: 2007-01-24 14:23
yes but

saving something on C:\ is not what we call "portable", do we? Wink

If a packet hits a pocket on a socket on a port,
and the bus is interrupted as a very last resort,
and the address of the memory makes your floppy disk abort,
then the socket packet pocket has an error to report Biggrin

rab040ma
Offline
Last seen: 2 days 14 hours ago
Joined: 2007-08-27 13:35
Depends on your needs. Many

Depends on your needs. Many of the programs here do make temporary files on the C: drive (or another fixed disk) and even write settings in the registry. The test is whether they remove themselves (or get removed) after the program exits. For some people even that is too high a risk, and they should check to find out which portable apps here do that.

U3 apps get removed pretty thoroughly because they are running from the fixed disk. They can be gracefully closed if the drive is pulled out prematurely, and another, dedicated program also running on the fixed disk can delete them. I wouldn't lay any bets on whether they were thoroughly deleted (that is, whether they could be undeleted by that sort of utility), but at least they do not show up.

Especially temporary files (that don't contain confidential information) can speed up access and reduce wear on a Flash drive when they are stored on and deleted from the fixed disk.

So it depends on your definition of Portable, and your susceptibility to someone dredging up deleted files from the hard disk.

The other issue is that changes that you want to keep get stored onto the removable drive before it is removed, even those stored temporarily on the fixed disk.

I think there are some criteria we all agree with (insert the drive and run the programs without installing, and keep settings and data when you leave) but the details of whether or not temporary files are used (and deleted) is subject to individual needs.

MC

Aciago
Aciago's picture
Offline
Last seen: 6 months 4 days ago
Joined: 2007-01-24 14:23
Well

I don't want any of my data on the host PC... I have a U3 drive too and I use to delete the file that the drive stores on the host PC.

and BTW, for us, this is a Portable App... https://portableapps.com/about/what_is_a_portable_app

If a packet hits a pocket on a socket on a port,
and the bus is interrupted as a very last resort,
and the address of the memory makes your floppy disk abort,
then the socket packet pocket has an error to report Biggrin

Log in or register to post comments