Click Here
Home Blog Gallery Links Tutorials Projects
[C++] Adding a program to Startup 2011-06-16 16:10
A nice c++ example how to add a program to startup is here. All you nead to add this to your code. it utilizes windows api btw. The example is below.

HKEY hkey;
char szBuf[] = "C:\\Windows\\notepad.exe";
RegOpenKeyEx(HKEY_LOCAL_MACHINE, "Software\\Microsoft\\Windows\\Currentversion\\Run", 0, KEY_SET_VALUE, &hkey);
RegSetValueEx (hkey, "notepad.exe", 0, REG_SZ, (LPBYTE) szBuf, strlen(szBuf) + 1);
RegCloseKey(hkey);

full code below.
http://pastebin.com/LSHzGJE6
<< [PHP] Curl: Get contents of a remote file and output it to browser Video: Masm32 Hacks: Create an AutoTyper for Notepad >>
All Entries

Add a Comment

Get Your IP Instantly
Name:
Enter the text shown in the image (case sensitive):
Email:

The site engine has been coded from scratch. The modules are coded separately eath other.
Server Time: 00:12. Dates and times are shown in Lithuanian (GMT +2) timezone
Name:
Password:

Enter Captcha (Case Sensitive):


Register
English
Lietuviškai

RSS Feed
Main Content
Carmageddon
Programming
Technology
Electronics
Linux
Anything
Site Info

Unique visit count:
3 visits on page.
3603 visits on site.
Detailed Statistics