Имя пользователя:
Пароль:
 

Показать сообщение отдельно

Новый участник


Сообщения: 4
Благодарности: 1

Профиль | Отправить PM | Цитировать


Люди хелп. Не знаю что делать. Сделал скрипт в котором в середине выполняется UninsHS.exe (пока его не всовывал) скрипт работал норм, он и сейчас работает хорошо. НО он не хочет заменять в папке установки старые файлы на новые (( Подскажитееее пожалуйста, что можна сделать . Вот скрипт






[Setup]
AppID = asdf
AppName=asdf
AppVersion=1.55.1
AppPublisher=Company
DefaultDirName={pf}\asdf
DefaultGroupName=asdf
AllowNoIcons=yes
LicenseFile=C:\Peter work\instalation script\files for install\legal.txt
OutputBaseFilename=setup
Compression=lzma

SolidCompression=yes
UninstallDisplayIcon = {app}\asdf,0
UninstallDisplayName = Uninstall asdf

; For modify button in control panel
AppModifyPath ="{app}\asdf" /m0=asdf

[Languages]


[Components]


[Tasks]
Name: "desktopicon"; Description: "{cm:CreateDesktopIcon}"; GroupDescription: "{cm:AdditionalIcons}"; Flags: unchecked
Name: "quicklaunchicon"; Description: "{cm:CreateQuickLaunchIcon}"; GroupDescription: "{cm:AdditionalIcons}"; Flags: unchecked; OnlyBelowVersion: 0,6.1
Name: quicklaunchicon7; Description: {cm:CreateQuickLaunchIcon}; GroupDescription: {cm:AdditionalIcons}; Flags: unchecked; MinVersion: 0,6.1
[Files]

Source: "C:\Peter work\instalation script\files for install\icon.ico"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\Peter work\instalation script\files for install\legal.txt"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:\Peter work\instalation script\files for install\UninsHs.exe"; DestDir: "{app}"; Flags: restartreplace
Source: "C:\Peter work\instalation script\files for install\play.jpg"; DestDir: "{app}"; Flags: restartreplace
Source: "C:\Peter work\instalation script\files for install\background.jpg"; DestDir: "{app}"; Flags: restartreplace
Source: "C:\Peter work\instalation script\files for install\asdf.exe"; DestDir: "{app}"; Flags: ignoreversion recursesubdirs createallsubdirs

[Dirs]
; Create folder for saving installation package
Name: "{userappdata}\$Inst$"; Attribs: hidden; Flags: uninsalwaysuninstall

[Icons]
Name: "{group}\asdf"; Filename: "{app}\asdf.exe"
Name: "{group}\{cm:UninstallProgram,asdf}"; Filename: "{uninstallexe}"
Name: "{commondesktop}\asdf"; Filename: "{app}\asdf.exe"; Tasks: desktopicon
Name: "{userappdata}\Microsoft\Internet Explorer\Quick Launch\asdf"; Filename: "{app}\asdf.exe";
Name: "{userappdata}\Microsoft\Internet Explorer\Quick Launch\User Pinned\TaskBar\asdf"; Filename: "{app}\asdf.exe"
Name: {group}\Uninstall asdf;Filename: "{app}\UninsHs.exe"; WorkingDir: "{app}"; Parameters: /u0=asdf

[InstallDelete]
Type: dirifempty; Name: "{userappdata}\$Inst$"

[Run]
; Register UninsHs to control panel
Filename: "{app}\UninsHS.exe"; Parameters: "/r0=asdf,{language},{srcexe},{userappdata}\$Inst$\setup.exe";WorkingDir: "{app}"; Flags: runhidden runminimized skipifdoesntexist
Filename: "{app}\asdf.exe"; Description: "{cm:LaunchProgram,asdf}"; Flags: nowait postinstall skipifsilent
[UninstallDelete]
; Delete the installation file

Type: files; Name: "{userappdata}\$Inst$\setup"

; Delete the installation folder

Type: dirifempty; Name: "{userappdata}\$Inst$"

[code]
{For UninsHs; Skip some wizard page when repair}
function ShouldSkipPage(CurPage: Integer): Boolean;
begin
if Pos('/SP-', UpperCase(GetCmdTail)) > 0 then
case CurPage of
wpLicense, wpPassword, wpInfoBefore,
//UserPage.Id,
wpUserInfo, wpSelectDir, wpSelectProgramGroup, wpInfoAfter:
Result := True;
end;
end;

function NextButtonClick(CurPage: Integer): Boolean;
var
sz:Integer;
s:string;
count:integer;
ErrorCode:integer;
ResultCode:integer;
res:integer;
begin
Result:=True;
count:=0;
If CurPage=wpSelectDir then

begin

if FileExists(ExpandConstant('{app}\UninsHS.exe')) and (count=0) then
begin

ShellExec('', ExpandConstant('{app}\UninsHS.exe'), '/u0=asdf', '', SW_SHOW, ewNoWait, ErrorCode);
Exec('taskkill', '/f /im setup.tmp', '', SW_Hide, ewNoWait, ErrorCode);
// Exec(ExpandConstant('{app}\UninsHS.exe'), ' /u0=asdf',ExpandConstant('{app}'),SW_SHOW,ewWaitUntilTerminated,res);



//
count:=1;

Result := False;
end ;


end;
end;


end .

ну не ужели никто не может помочь ? подсказать - почему файлы после переустановки не обновляються (

Последний раз редактировалось Petruchodd, 09-12-2010 в 14:57. Причина: никто не помог (((


Отправлено: 18:53, 08-12-2010 | #81