- Másodszor is nekifut az AI PC-k meghódításának a Qualcomm
- Megjött a Chieftec VEGA M szériás tápok legnagyobb teljesítményű kiadása
- 280 Hz-es, remekül felszerelt WOLED monitor jött a Gigabyte gondozásában
- Itt az AI videók TikTokja, az OpenAI új agymenése
- Rekordösszegért kerül szaúdi kézbe az Electronic Arts
- Melyik tápegységet vegyem?
- Fejhallgató erősítő és DAC topik
- 280 Hz-es, remekül felszerelt WOLED monitor jött a Gigabyte gondozásában
- Milyen billentyűzetet vegyek?
- Szünetmentes tápegységek (UPS)
- AMD Ryzen 9 / 7 / 5 9***(X) "Zen 5" (AM5)
- Másodszor is nekifut az AI PC-k meghódításának a Qualcomm
- HiFi műszaki szemmel - sztereó hangrendszerek
- Projektor topic
- AMD Ryzen 9 / 7 / 5 7***(X) "Zen 4" (AM5)
Új hozzászólás Aktív témák
-
pIIrash
tag
unit un_RMethods;
interface
uses Windows, SysUtils, Registry;
const
CurVer = 'SOFTWARE\Microsoft\Windows\CurrentVersion\';
R_UninstPrg = CurVer + 'Uninstall';
R_RUN = CurVer + 'Run';
procedure SetStartWithWindows(AppName, AppTitle: string);
procedure SetRegistryValue(RootKey: HKEY; Key, KeyName, Value, regType: string);
implementation
procedure SetRegistryValue(RootKey: HKEY; Key, KeyName, Value, regType: string);
var
Registry: TRegistry;
begin
Registry := TRegistry.Create;
with Registry do
begin
try
RootKey := RootKey;
if OpenKey(Key, False) then
begin
if regType = 'STR' then WriteString(KeyName, Value);
if regType = 'BOL' then WriteBool(KeyName, StrToBool(Value));
if regType = 'INT' then WriteInteger(KeyName, StrToInt(Value));
end;
finally
Free;
end;
end;
end;
function GetRegistryValue(RootKey: HKEY; Key, Value, regType: string): string;
var
Registry: TRegistry;
TempValue: string;
begin
Registry := TRegistry.Create;
with Registry do
begin
try
RootKey := RootKey;
if OpenKey(Key, False) then
begin
if regType = 'STR' then TempValue := Registry.ReadString(Value);
if regType = 'BOL' then TempValue := BoolToStr(ReadBool(Value));
if regType = 'INT' then TempValue := IntToStr(ReadInteger(Value));
end;
finally
Free;
end;
end;
Result := TempValue;
end;
pl: beírás:
procedure SetStartWithWindows(AppName, AppTitle: string);
begin
SetRegistryValue(HKEY_LOCAL_MACHINE, R_RUN, <Program elérési útja>, <Program neve>, 'STR');
end;
pl: kiolvasás:
InstallPath := GetRegistryValue(HKEY_LOCAL_MACHINE, SOFTWARE\<A program neve>\, A kulcs amiből olvasni akarsz);
Remélem segít!
[Szerkesztve]
Új hozzászólás Aktív témák
- Asus Rog ALLY Z1 Extrem
- Új, bontatlan, iPhone 17 Air gyárilag kártya-független, apple világgaranciával
- Apple iPhone 13 Pink Super Retina XDR, 5G, dupla kamera 128 GB Használt, karcmentes 100%
- Apple iPhone 13 Pro Alpine Green ProMotion 120 Hz, Pro kamerák 128 GB-100%
- Apple iPhone 13 Pro Max Sierra Blue ProMotion 120 Hz, Pro kamerák 128 GB Használt, szép,100%
Állásajánlatok
Cég: Laptopműhely Bt.
Város: Budapest
Cég: PCMENTOR SZERVIZ KFT.
Város: Budapest