2012年7月14日 星期六

About Inno Setup for MFC application

This website lists some important DLLs that MFC application will use.

And also set to have administrative privileges NT/2K/XP.
Also refer to Inno Setup example scripts.

http://www.jrsoftware.org/iskb.php?vc

2 則留言:

  1. The code below can used to detect windows system and more detail see Inno setup help about Windows version.

    // Check if Windows 2000 and SP4
    if Version.NTPlatform and
    (Version.Major = 5) and
    (Version.Minor = 0) and
    (Version.ServicePackMajor < 4) then
    begin
    SuppressibleMsgBox('Windows 2000 need to install Service Pack 4.',
    mbCriticalError, MB_OK, MB_OK);
    Result := False;
    Exit;
    end;

    http://www.cnblogs.com/pyw0818/archive/2011/01/22/1941963.html

    回覆刪除
  2. I need to add device driver before installing main application.

    Just add exec function in InitializeSetup such as the code below.

    function InitializeSetup(): Boolean;
    begin
    WorkingDir := ExpandConstant ('{tmp}');
    ExtractTemporaryFile ('1.exe');
    ExtractTemporaryFile ('2.exe');
    ExtractTemporaryFile ('3.cmd');

    Exec (ExpandConstant ('{tmp}\1.exe'), '', ExpandConstant ('{tmp}'), SW_Show, ewNoWait, ReturnCode);

    Exec (ExpandConstant ('{tmp}\2.exe'), '', ExpandConstant ('{tmp}'), SW_Show, ewNoWait, ReturnCode);

    Exec (ExpandConstant ('{cmd}'), '/C 3.cmd', ExpandConstant ('{tmp}'), SW_Show, ewWaitUntilTerminated, ReturnCode);

    from http://bbs.hanzify.org/simple/?t59170.html

    回覆刪除