Startup Program

Miscellaneous Forums/Win32 Discussion/Startup Program

The forum is locked. These are the original blitzbasic.com forums, kept so they can still be read. No new topics, replies or edits can be made here. To join in, head over to the Blitz3D+ forums.

Uses this: http://www.blitzbasic.com/codearcs/codearcs.php?code=1991

Function SetStartupRegValue:Int(Value:String, ValueData:String) 
  Local temp:tregkey = OpenRegKey("HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Run") 
	
	If temp
		
		If temp.SetString(Value, valuedata) 
		   Return True
			
		EndIf
		
	EndIf
	
   Return False
   
End Function

Print SetStartupRegValue("testapp", "c:\test.exe") 
Input() 
End