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 / Accesing the whole Registry!

Author
Message
MadrMan
18
Years of Service
User Offline
Joined: 17th Dec 2005
Location: 0x5AB63C
Posted: 18th Mar 2006 09:30 Edited at: 18th Mar 2006 09:35
Here they are, some code snippets that prevent you from only going into the local user or useing dll's

"Get String"
usage:
a$=getreg$("HKEY_LOCAL_MACHINE/SYSTEM/CurrentControlSet/Control/Session Manager/Environment","PROCESSOR_IDENTIFIER")
Should get your processor name/model.
(this one isn' Too fast..)


"Fix Slash"
if getting strings from the registry it usally has a double slash, like "C:dirfile.txt"
usage:
goodstring$=fixslash(badstring$)


"Put String"
use for importing strings to the registry.
usage:
writereg("HKEY_CLASSES_ROOT/DarkBasicPro.Project/shell/print/command","","%SystemRoot%system32NOTEPAD.EXE /p %1")
note: ""=(default)



(just to let you know, this example would give the .dba files a 'print' on right-click)

note: don't use a double slash on the key name or path, only on the value, or it won't import.

Hope you'll like it

we'll all turn mad someday..

Login to post a reply

Server time is: 2024-05-19 06:57:36
Your offset time is: 2024-05-19 06:57:36