PDA

View Full Version : deleting files



GuroT
02-04-2002, 05:28 PM
i want every time when i enter windows to delete a certain file
what to put in HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\Curr entVersion\Run to do this?

jdharm
02-04-2002, 06:29 PM
Open notepad, type:

@echo off
del "c:\<file path>"
@cls

Save this as "delete.bat" and put it in the startup folder. No need to edit the registry unless you just want to.

Or add "del c:\<file path>" to your autoexec.bat if you have one.

For what it worth.
I'm just making this up as I go along.
Scoff, ignore, or flame at will.

GuroT
02-05-2002, 11:07 AM
i know this method but i can't use DOS commands.i have to delete the file from the registry.i'm thinking for a dll file something like rundll.exe user.exe,exitwindowsexec-to delete files under windows not under DOS!!!anyway thanks jdharm!!!

Smitty
02-05-2002, 02:33 PM
Guro T

Try this site while you wait..<a target="_blank" href=http://www.robvanderwoude.com/rundll.html>Rundll Batch Files</a>



Smitty

GuroT
02-05-2002, 06:22 PM
thanks a lot Smitty

POBrien
02-05-2002, 06:27 PM
How come you can't use dos commands? What's the setup like... stand alone or a network environment? Is this for 98, 2000?

You can create a batch file with the commands and then add the reg entry to execute the batch file on Windows Startup. You can house the batch file in the c:\ drive. If this is on a network you can copy down the batch file first via the login script and then execute a reg file after the file is copied down.

If you use this method, you would have to use HKey_Current_User....Run in the reg file as opposed to Hkey_Local_Machine.


Patrick (http://www.winguides.com/forums/sendprivate.php?Cat=&User=POBrien&Board=&Number=&what=online&page=&view=&sb=&part=&vc=><font)</font color=green> /images/forums/icons/smile.gif
<a target="_blank" href=https://www.regnow.com/softsell/nph-softsell.cgi?item=5006-1>WinGuides</a>

GuroT
02-06-2002, 10:30 AM
the point is that i don't want the DOS prompt window to appear and i can't use autoexec.bat and winstart.bat.my os is win'98se.i want the process to be hidden!!!

jdharm
02-06-2002, 04:04 PM
Third party app called Runfile runs scrips and batch files without the popup command window or taskbar icons. Just drop the executable in the Windows directory and run the batch with the syntax:

runfile CMD=file name

Still get an hourglass cursor, but that is it. Works great. Freeware. Actually, "Breatheware" as the developer calls it.

<a target="_blank" href=http://www.rebirthing.co.nz/re/RunfileDL.html>http://www.rebirthing.co.nz/re/RunfileDL.html</a>



For what it worth.
I'm just making this up as I go along.
Scoff, ignore, or flame at will.