I can't see any reason why you'd want to do an actual, full reset of the program. If all you're doing is starting the program again (ie, a reset??), save time by keeping the necessary assets loaded, and just branch control back to the start of the program. Delete unnecessary assets on the fly, as they become unneeded.
Loading a second instance of the same program and immediately terminating the current instance seems crazy. Assets get unloaded anyway when you hit an END in the program (this is why the disk keeps accessing and the OS seems a little slow after you quit any resource-heavy program, including DBPro games), and the new instance of the program will have to load some or all of your resources again. Very messy.
Stick a REPEAT at the point of your code where you want to loop back to, and an UNTIL at the end of the code, the condition being a flag that you set when you want to trigger the reset. Then wrap the whole REPEAT UNTIL loop in another REPEAT UNTIL loop whose condition is a flag you set when you want to quit the whole program. Above the top layer loop is where you put your asset load instructions, and below it is where you put your asset unload code - or nothing, and your program will clean up after itself automatically on quit.
Quote: "If you want to get rid of images and objects loaded as well using SET DISPLAY MODE will erase all that."
Holy sh!t.
As soon as I read that, my mind went "That doesn't sound right, Groggy's gone nuts" and went immediately to test it. He's friggin' right - everything gets freed up when you issue a SET DISPLAY MODE.
load image "test.jpg", 1
set display mode 640,480,32
paste image 1, 1, 1
do: sync: loop
This code throws an Image Does Not Exist error. Comment out the SET DISPLAY MODE command and the image displays just fine.
How irregular!