Registrye eklenen programın adını bu şekilde alıyorum peki dosyanın bulunduğu konumunu nasıl memoya yazdırabilirim
Kod: Tümünü seç
procedure TRegistryKeyCache.GenerateDifferenceReport(Report:TStringList);
var
i : Integer;
NewKeysList : TStringList;
NewValuesList : TStringList;
RemovedKeysList : TStringList;
RemovedValuesList : TStringList;
S,Path: string ;
begin
if not Assigned(Report) then exit;
NewKeysList := TStringList.Create;
NewValuesList := TStringList.Create;
RemovedKeysList := TStringList.Create;
RemovedValuesList := TStringList.Create;
try
CreateAdditionalDifferenceList(NewKeysList, NewValuesList );
CreateRemovedDifferenceList (RemovedKeysList,RemovedValuesList);
for i := 0 to NewKeysList.Count - 1 do
begin
Report.Add(Format('%s added key "%s" to %s',[TimeToStr(Time),NewKeysList[i],(RootKeyToString(FRootKey) + '\' + FKey)]));
end;
for i := 0 to NewValuesList.Count - 1 do
begin
Report.Add(Format('%s added value "%s" to %s',[TimeToStr(Time),NewValuesList[i],(RootKeyToString(FRootKey) + '\' + FKey)])); // dosyanın adını alıyorum
end;
end;