Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

DarkBASIC Professional Discussion / Running a program at start up.

Author
Message
Dsarchy
22
Years of Service
User Offline
Joined: 4th Oct 2003
Location: UK- Kent
Posted: 27th Oct 2003 13:55
Is it possible to make a program in DBP and allow it to have the option of running at start up. Like applications like MSN messenger and Antivirus software?

"A Chain Is Only As Strong As Its Weakest Link"
Surreal Studio IanG
22
Years of Service
User Offline
Joined: 21st Sep 2003
Location: Cyberspace...I think
Posted: 27th Oct 2003 14:04
yeah, you just make it so it can create a shorcut in the startup folder
C:\WINDOWS\Start Menu\Programs\StartUp\
that is what Norton's cleansweep does and i think messenger does the same.
Genesis Rage
22
Years of Service
User Offline
Joined: 5th Oct 2003
Location:
Posted: 27th Oct 2003 16:00
most norton and messenger services like that will make an entry into you regestry file... so it doesnt put anything in your startup... they do this becuase the registry will load WITH windows, as the startup folder loads AFTER windows...

as to do this in DarkBASIC Pro or Classic, i highly doubt you can do it with native commands... there may be a dll or some other external file or application that may help you... but as for DB i am not aware of it to be able to do that

==Main Computer==
Athlon XP 3000+, 1024mb, Radeon 9800 Pro 128mb 8xAGP, XP Pro
Surreal Studio IanG
22
Years of Service
User Offline
Joined: 21st Sep 2003
Location: Cyberspace...I think
Posted: 28th Oct 2003 14:47
nortons cleansweep does put a shortcut in the startup folder and i thought messenger did the same
orv
22
Years of Service
User Offline
Joined: 9th Sep 2003
Location: Chicago, IL
Posted: 28th Oct 2003 15:17
there are two types of startup:

1. how Phoenix_insane mentions. These programs run after you log into Windows.

2. how Genesis Rage mentions. There is a Services part of the registry that specifies program to run when Windows starts up. These will be running before the user types in their userid and password to log in. Services are for things you want running in the background BEFORE the user is logged in or WHILE the user is logged out! Example: Anti Virus software. You don't just want it scanning your machine when you're logged in!

Some software such as anti virus software will use both methods.
One program will start as a service before the login to monitor the system to make sure it doesn't get infected. Another program will start from the Startup folder and put an icon in the system tray for the user to click on to bring up a GUI after they're logged in.

For games, putting a shortcut in the startup folder is probably more than adiquate!

hope this help!

If you aim at nothing you'll hit it every time. 806mhz AMD Athlon Processor. 384MB memory.
Windows XP Home Edition. RADEON 9700 Pro graphics card. - editor.exe=1.0.6.1 - DBPCompiler.exe=V1.05
zircher
23
Years of Service
User Offline
Joined: 27th Dec 2002
Location: Oklahoma
Posted: 28th Oct 2003 15:17
Check out My Computer\HKEY_CURRENT_USER\Software\microsoft\windows\CurrentVersion\Run with regedit. There are start ups there.

Unless you're making a system utility, the start up folder is good enough for most programs.
--
TAZ
BatVink
Moderator
23
Years of Service
User Offline
Joined: 4th Apr 2003
Location: Gods own County, UK
Posted: 28th Oct 2003 15:25 Edited at: 28th Oct 2003 15:27
Stick it in the

HKEY_USERS\.DEFAULT\Software\Microsoft\Windows\CurrentVersion\Run

registry section.

[edit] doh...beaten to it...still, just reinforcing the point!

BatVink (formerly StevieVee)
http://facepaint.me.uk/catalog/default.php
Van B
Moderator
23
Years of Service
User Offline
Joined: 8th Oct 2002
Location: Sunnyvale
Posted: 28th Oct 2003 15:36
Nah, leave the registry alone, a shorcut, copied to the startup directory is far more convenient. I hate how some companies make it a nightmare to uninstall their software, personally I prefer being able to simply delete the files.

Imagine, if every company did that, and every company stored their softwares settings in setup files instead - I'd bet we'd have much more reliable PC's - plus you'd be able to reinstall windows and not necesserily have to reinstall all your software.


Van-B

zircher
23
Years of Service
User Offline
Joined: 27th Dec 2002
Location: Oklahoma
Posted: 29th Oct 2003 01:51
Speaking of nightmares even look at what DirectInput does? Each one of my DBPro builds has a registry entry. Man, there are dozens of not hundreds of them in there for each project/exe.
--
TAZ
Surreal Studio IanG
22
Years of Service
User Offline
Joined: 21st Sep 2003
Location: Cyberspace...I think
Posted: 29th Oct 2003 13:07 Edited at: 29th Oct 2003 13:09
If you make a mistake in your registry it could stop your computer from loading windows - putting a shorcut in the startup folder is much safer, and you don't have to know anything about the registry

Flick that switch...*BANG*...Not that one!

Login to post a reply

Server time is: 2026-07-26 20:17:24
Your offset time is: 2026-07-26 20:17:24