AlekseyPopovv
14-08-2014, 12:52
Ребята помогите решить проблему: скрипт собирается, файл запускается всё устанавливается. Ошибка возникает при удалении после окошка "Нажмите кнопку "OK" и удалите не нужные Вам параметры программы {#MyAppName} {#MyAppVersion}.". Скрипт на две программы (Beauty.Checked и Brightness.Checked). Как решить эту проблему?
[Messages]
UninstalledAll=Нажмите кнопку "OK" и удалите не нужные Вам параметры программы {#MyAppName} {#MyAppVersion}.
procedure CurUninstallStepChanged(CurUninstallStep: TUninstallStep);
begin
if (CurUninstallStep = usDone) then
begin
if Beauty.Checked then
RegDeleteKeyIncludingSubkeys(HKCR, 'bmp_auto_file\shell\Beauty Guide');
if Beauty.Checked then
RegDeleteKeyIncludingSubkeys(HKCR, 'jpegfile\shell\Beauty Guide');
if Beauty.Checked then
RegDeleteKeyIncludingSubkeys(HKCR, 'pngfile\shell\Beauty Guide');
if Beauty.Checked then
RemoveDir(ExpandConstant('{group}'));
end;
begin
if (CurUninstallStep = usDone) then
begin
if Beauty.Checked then
if MsgBox('Удалить Ваши настройки Beauty Guide?',mbconfirmation, mb_yesno) = IDYES then
begin
if Beauty.Checked then
DelTree(ExpandConstant('{userappdata}\BeautyGuide'), True, True, True);
end;
begin
if (CurUninstallStep = usDone) then
begin
if Beauty.Checked then
if MsgBox('Удалить плагины Beauty Guide?',mbconfirmation, mb_yesno) = IDYES then
begin
if Beauty.Checked then
DeleteFile(ExpandConstant('{pf32}\Tint Guide\Photo Plugins\BeautyGuidePlugin.8bf'));
DeleteFile(ExpandConstant('{pf}\Tint Guide\Photo Plugins64\BeautyGuidePlugin64.8bf'));
RemoveDir(ExpandConstant('{pf32}\Tint Guide\Photo Plugins'));
RemoveDir(ExpandConstant('{pf32}\Tint Guide'));
RemoveDir(ExpandConstant('{pf}\Tint Guide\Photo Plugins64'));
RemoveDir(ExpandConstant('{pf}\Tint Guide'));
begin
if (CurUninstallStep = usDone) then
begin
if Beauty.Checked then
if MsgBox('Программа {#MyAppNameBeauty} {#MyAppBeautyVersion} удалена!',mbconfirmation, mb_ok) = IDYES then
end;
end;
end;
end;
end;
end;
end;
begin
if (CurUninstallStep = usDone) then
begin
if Brightness.Checked then
RegDeleteKeyIncludingSubkeys(HKCR, 'bmp_auto_file\shell\Brightness Guide');
if Brightness.Checked then
RegDeleteKeyIncludingSubkeys(HKCR, 'jpegfile\shell\Brightness Guide');
if Brightness.Checked then
RegDeleteKeyIncludingSubkeys(HKCR, 'pngfile\shell\Brightness Guide');
if Brightness.Checked then
RemoveDir(ExpandConstant('{group}'));
end;
begin
if (CurUninstallStep = usDone) then
begin
if Brightness.Checked then
if MsgBox('Удалить Ваши настройки Brightness Guide?',mbconfirmation, mb_yesno) = IDYES then
begin
if Brightness.Checked then
DelTree(ExpandConstant('{userappdata}\BrightnessGuide'), True, True, True);
end;
begin
if (CurUninstallStep = usDone) then
begin
if Brightness.Checked then
if MsgBox('Удалить плагины Brightness Guide?',mbconfirmation, mb_yesno) = IDYES then
begin
if Brightness.Checked then
DeleteFile(ExpandConstant('{pf32}\Tint Guide\Photo Plugins\BrightnessGuidePlugin.8bf'));
DeleteFile(ExpandConstant('{pf}\Tint Guide\Photo Plugins64\BrightnessGuidePlugin64.8bf'));
RemoveDir(ExpandConstant('{pf32}\Tint Guide\Photo Plugins'));
RemoveDir(ExpandConstant('{pf32}\Tint Guide'));
RemoveDir(ExpandConstant('{pf}\Tint Guide\Photo Plugins64'));
RemoveDir(ExpandConstant('{pf}\Tint Guide'));
begin
if (CurUninstallStep = usDone) then
begin
if Brightness.Checked then
if MsgBox('Программа {#MyAppNameBrightness} {#MyAppBrightnessVersion} удалена!',mbconfirmation, mb_ok) = IDYES then
end;
end;
end;
end;
end;
end;
end;
end;
[Messages]
UninstalledAll=Нажмите кнопку "OK" и удалите не нужные Вам параметры программы {#MyAppName} {#MyAppVersion}.
procedure CurUninstallStepChanged(CurUninstallStep: TUninstallStep);
begin
if (CurUninstallStep = usDone) then
begin
if Beauty.Checked then
RegDeleteKeyIncludingSubkeys(HKCR, 'bmp_auto_file\shell\Beauty Guide');
if Beauty.Checked then
RegDeleteKeyIncludingSubkeys(HKCR, 'jpegfile\shell\Beauty Guide');
if Beauty.Checked then
RegDeleteKeyIncludingSubkeys(HKCR, 'pngfile\shell\Beauty Guide');
if Beauty.Checked then
RemoveDir(ExpandConstant('{group}'));
end;
begin
if (CurUninstallStep = usDone) then
begin
if Beauty.Checked then
if MsgBox('Удалить Ваши настройки Beauty Guide?',mbconfirmation, mb_yesno) = IDYES then
begin
if Beauty.Checked then
DelTree(ExpandConstant('{userappdata}\BeautyGuide'), True, True, True);
end;
begin
if (CurUninstallStep = usDone) then
begin
if Beauty.Checked then
if MsgBox('Удалить плагины Beauty Guide?',mbconfirmation, mb_yesno) = IDYES then
begin
if Beauty.Checked then
DeleteFile(ExpandConstant('{pf32}\Tint Guide\Photo Plugins\BeautyGuidePlugin.8bf'));
DeleteFile(ExpandConstant('{pf}\Tint Guide\Photo Plugins64\BeautyGuidePlugin64.8bf'));
RemoveDir(ExpandConstant('{pf32}\Tint Guide\Photo Plugins'));
RemoveDir(ExpandConstant('{pf32}\Tint Guide'));
RemoveDir(ExpandConstant('{pf}\Tint Guide\Photo Plugins64'));
RemoveDir(ExpandConstant('{pf}\Tint Guide'));
begin
if (CurUninstallStep = usDone) then
begin
if Beauty.Checked then
if MsgBox('Программа {#MyAppNameBeauty} {#MyAppBeautyVersion} удалена!',mbconfirmation, mb_ok) = IDYES then
end;
end;
end;
end;
end;
end;
end;
begin
if (CurUninstallStep = usDone) then
begin
if Brightness.Checked then
RegDeleteKeyIncludingSubkeys(HKCR, 'bmp_auto_file\shell\Brightness Guide');
if Brightness.Checked then
RegDeleteKeyIncludingSubkeys(HKCR, 'jpegfile\shell\Brightness Guide');
if Brightness.Checked then
RegDeleteKeyIncludingSubkeys(HKCR, 'pngfile\shell\Brightness Guide');
if Brightness.Checked then
RemoveDir(ExpandConstant('{group}'));
end;
begin
if (CurUninstallStep = usDone) then
begin
if Brightness.Checked then
if MsgBox('Удалить Ваши настройки Brightness Guide?',mbconfirmation, mb_yesno) = IDYES then
begin
if Brightness.Checked then
DelTree(ExpandConstant('{userappdata}\BrightnessGuide'), True, True, True);
end;
begin
if (CurUninstallStep = usDone) then
begin
if Brightness.Checked then
if MsgBox('Удалить плагины Brightness Guide?',mbconfirmation, mb_yesno) = IDYES then
begin
if Brightness.Checked then
DeleteFile(ExpandConstant('{pf32}\Tint Guide\Photo Plugins\BrightnessGuidePlugin.8bf'));
DeleteFile(ExpandConstant('{pf}\Tint Guide\Photo Plugins64\BrightnessGuidePlugin64.8bf'));
RemoveDir(ExpandConstant('{pf32}\Tint Guide\Photo Plugins'));
RemoveDir(ExpandConstant('{pf32}\Tint Guide'));
RemoveDir(ExpandConstant('{pf}\Tint Guide\Photo Plugins64'));
RemoveDir(ExpandConstant('{pf}\Tint Guide'));
begin
if (CurUninstallStep = usDone) then
begin
if Brightness.Checked then
if MsgBox('Программа {#MyAppNameBrightness} {#MyAppBrightnessVersion} удалена!',mbconfirmation, mb_ok) = IDYES then
end;
end;
end;
end;
end;
end;
end;
end;