Registriert seit: 19. Apr 2003
1.291 Beiträge
Delphi 2005 Professional
|
Re: Inno Setup - {userappdata} aller User des Systems ermitt
14. Aug 2005, 17:42
Ich hab mir jetzt was gebastelt um an alle bettr. Ordner heran zu kommen...
Delphi-Quellcode:
procedure CurUninstallStepChanged(CurUninstallStep: TUninstallStep);
var
UserFolders, Appdata, Users, Folder:string;
FindRec: TFindRec;
begin
if CurUninstallStep=usPostUninstall then
begin
UserFolders := ExpandConstant('{commonappdata}');
if Copy(UserFolders, Length(UserFolders),1) = '\' then
UserFolders := Copy(UserFolders, 1, Length(UserFolders) - 1);
While Copy(UserFolders, Length(UserFolders), 1) <> '\' do
UserFolders := Copy(UserFolders, 1, Length(UserFolders) - 1);
AppData := Copy(ExpandConstant('{commonappdata}'), Length(UserFolders), Length(ExpandConstant('{commonappdata}')));
UserFolders := Copy(UserFolders, 1, Length(UserFolders) - 1);
While Copy(UserFolders, Length(UserFolders), 1) <> '\' do
UserFolders := Copy(UserFolders, 1, Length(UserFolders) - 1);
if FindFirst(ExpandConstant(UserFolders + '\*'), FindRec) then
begin
try
repeat
if Copy(FindRec.Name, 1, 1) <> '.' then
begin
Folder := UserFolders + FindRec.Name + Appdata;
if DirExists(Folder) = True then
begin
//Do something...
msgbox(Folder, mbInformation, mb_Ok);
end;
end;
until not FindNext(FindRec);
finally
FindClose(FindRec);
end;
end;
end;
end;
Elektronische Bauelemente funktionieren mit Rauch. Kommt der Rauch raus, geht das Bauteil nicht mehr.
|
|
Zitat
|