Making sure a program ALWAYS runs....

I wrote this program that I want to run everytime I turn my computer on. I know that I can put it in the autoexec.bat but I have been having some troubles with that file recently. So is there any other way to make sure my program will run upon boot?
GreatOneAsked:
Who is Participating?
 
Dane PickeringConnect With a Mentor Commented:
I am not sure if this is what you want, but this is the only place that no-one has mentioned (provided that you are using windows 95) follow these steps.


Click on start > run
type in REGEDIT and click ok
regedit will load up,
double click the following :-

HKEY_LOCAL_MACHINE
Software
Microsoft
Windows
CurrentVersion
Run

in here you will find a list of all files that are loaded by windows each time it is started up.  what you need to do now is right click your mouse button in the right hand panel
click on new and string
in name the string whatever you want.
after you make the string, highlight it and hit enter, you now enter the path/filename/paramaters that you want to run.

if you want to hide it as it is a dos app, you may need to make a pif file and have the reference in here to the pif file and have the exe on his hdd in a wierd folder that he won't even look in, or simply hide the file.

good luck, lemme know how you go.
-- Dane

0
 
mikecrCommented:
If your using Windows, you can put it into the startup group and it will run when Windows starts. The only other way to get it to start in Dos would be to use a call command in the autoexec.bat file to get it to run. I.e, @call c:\runnit.bat. Is this what your looking for?

Thanks,
Mike
0
 
GreatOneAuthor Commented:
I am trying to avoid putting stuff in my autoexec.bat file. Are you sure there is no other way?
0
Improved Protection from Phishing Attacks

WatchGuard DNSWatch reduces malware infections by detecting and blocking malicious DNS requests, improving your ability to protect employees from phishing attacks. Learn more about our newest service included in Total Security Suite today!

 
mikecrCommented:
Unless you put it in Windows startup, NO! The bootstrap loader turns control of the PC over to the operating system which in turn automatically runs autoexec.bat and config.sys if they are available. You could create a boot menu that would run a different autoexec.bat file instead of the screwed up one, but there isn't any other way that I know of.

Thanks,
Mike
0
 
tyloxCommented:
You say you don`t want to add anything to your autoexec.bat
files, so all I can suggest is to add the program to your
windows "startup" group.This will launch the program every
time you`re running windows:
1)press "Start"
2)select "Settings", then "Taskbar", click-on "Taskbar"
3)press "Start menu programs" tab
4)press "add"
5)type-in the path to the program, eg;C:\windows\myprogram\my.exe
6)scroll down to folder called "StartUp"(NOT to be confused
with "Start Menu")
7)highlight this folder and press "next"
8)Select a name for your program
9)Pick an icon you like and press "Finish"
10)Press "OK" and you`re done! This program will now always
auto-start whenever Windows is running.

PS: If it`s a Dos program you want to always run, you`ll have to edit your autiexec.bat file;-)
0
 
Chris RipollMaster of NoneCommented:
One other way if running windows; create a winstart.bat file in windows directory. Will execute winstart.bat command before launching windows.

NO OTHER WAY!!

CR
0
 
tyloxCommented:
GreatOne,
   Am I correct in assuming that this program is DOS?If so,
will it run in a dos-window? I have, I THINK, one other way
for you to do this.It`s rather inelegant, sort of a "Rube
Goldbergish"-type of setup, but MIGHT allow your computer to
launch a dos-program upon start-up without editing/creating any autoexec.bat/dosstart.bat files. It`s only theory, but I
think it *might* work.It would help if we knew a little more
about the program you want to auto-start, and it certainly wouldn`t hurt to post your existing autoexec.bat file here
for analysis.By far, the easiest way, is for you to "call"
the program in your autoexec.bat files...if you are "having
problems" with your current file, maybe we can help solve
what might be an existing *problem*, so that you could go
forward and call the program in your autoexec.bat file in a
more "accepted" and S.O.P.-type of way, rather than bastard-
ize some other part of your system, just to get this program
to launch automatically.More info would be helpful;-)
0
 
GreatOneAuthor Commented:
Tylox,
You want more info, well here you go. I wrote a little program for DOS that will change the background if it is a certain date. I want to put this on my friends computer but don't want him to know its there. He has problems with viruses in the past and now always checks what files are on his computer. He particularly checks the contents of autoexec.bat and config.sys. If i were to put in the windows start up group, he would see it running and would probably think its a virus. So that's the info. What would you do?
0
 
rin1010Commented:

  If you have access to your "friend's" autoexec.bat file, look to see if he's launching anything that he doesn't absolutely need. (e.g., MSCDEX, SMARTDRV, DOSKEY) If so, rename your program to one of those, put it in the proper path... Well, you get the idea...  Might fool him for a while....

  If you've compiled it as a DOS program, and it's made to run in the background, do its thing and close, you might have to create a pif so it doesn't open a window. Regardless... your best bet, (if he ain't too sharp) is add it to the Run or Launch line in WIN.INI, or go with the WINSTART.BAT idea...
0
 
tyloxCommented:
Now that you`ve "come clean"<g>regarding what it is you really
want to do, the fact that you want to hide the program`s very
existance from an obviously paranoid and rather overly diligent
friend, pretty much eliminates doing what *I* had in mind.You
might as well reject my answer now, and put it back up for the
others to take a stab-at.Sorry I couldn`t help you:-(
0
 
rin1010Commented:

 Launch line? Meant to say Lunch line.

0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.