Вы находитесь на странице: 1из 7

By DarkHunter

1: ( )
: RegShot, InnoSetup5 ( Inno), AutoIt3

1:
RegShot. !

2:
, .

Inno Setup ( Inno Script Generator)
"Registry"
- Add a Row
, RegShot' (
"Add a Row"!)
! ,
: MuiCache, Cache, cookies .

3:
, ... !
Inno Script Generator "Files and Dirs"
"Add a row"
1:
C:\Program Files\test for tracker
test for nnm-club
C:\Program Files\test for tracker\test.txt
:
Inno Script Generator "add a Row" Source C:\Program Files\test for tracker\test.txt
DestName test.txt !
{app} !
2:
Subfolder
: C:\Program Files\test for tracker\Dark\test.txt
, Subfolder ( Dark) ^)
.
? !
, system32, SysWow64, appData.
.
, "Destination: - Root"
. ( Program Files - {pf}; Application Data - {appdata}

. { }. ( )
, , . , {win}
"C:\WINDOWS", .
{ . "{", .
("\"), , .
, {const} "C:\", {const}\filensme, "C:\filename",
"C:\\filename", . "C:\\filename", :
{const} {\}\filename.
.
.
{app}
, . .
: {app}\MYPROG.EXE Source
"C:\MYPROG", "C:\MYPROG\MYPROG.EXE".
{win}

, Windows. : "{win}\MYPROG.INI", Windows "C:\WINDOWS",


"C:\WINDOWS\MYPROG.INI".
{sys}
Windows (System32 Windows NT).
: "{sys}\CTL3D32.DLL" Windows "C:\WINDOWS\SYSTEM",
"C:\WINDOWS\SYSTEM\CTL3D32.DLL".
{src}
, .
: "{src}\MYPROG.EXE", "S:\", "S:\MYPROG.EXE".
{sd}
. , Windows. "C:".
{pf}
Program Files. ( ). "C:\Program Files".
{cf}
Common Files. "C:\Program Files\Common Files".
{tmp}

. , ("C:\WINDOWS\TEMP\IS-xxxxx.tmp").
Temp . , [Run]
, , .
{fonts}
. FONTS Windows.
{dao}
DAO. {cf}\Microsoft Shared\DAO.
.

Inno Setup , . ,
.
"user" , "common"
.
, Windows, Inno Setup,
Windows 95 NT 4.0.

"common" "user", , , ,
Windows 95/98/Me.
{group}

, . Windows NT/2000/XP
, , ,
- .
{localappdata}
.
{sendto}
Send To ( Send To ).
{userappdata} & {commonappdata}
(Application Data).
{userdesktop} & {commondesktop} *
. {userdesktop}
{userdocs} & {commondocs}
( Windows NT 4.0 Personal folder).
{userfavorites} & {commonfavorites} *

. MinVersion "4.1, 4". Windows 2000, Me,


{commonfavorites}; Windows {commonfavorites} = {userfavorites}.
{userprograms} & {commonprograms} *
.
{userstartmenu} & {commonstartmenu} *
"" .
{userstartup} & {commonstartup} *
.
{usertemplates} & {commontemplates} *

. Windows 2000, Me, {commontemplates}; Windows, {commontemplates} =


{usertemplates}.
.
{\}
. {\} \.
{%NAME|DefaultValue}
.
NAME -
DefaultValue - , ,

, "|", "}" "%-_.".


. - "%2c", - "%7c", "}" - "%7d". "%" = "%25".
NAME DefaultValue .
, ,
. , .
:
{%COMSPEC}
{%PROMPT|$P$G}
{cmd}
. NT/2000/XP, Windows\System32\cmd.exe. Windows 9x/Me Windows\COMMAND.COM. COMSPEC .
{computername}
, ( GetComputerName).
{drive:Path}

(, "C:").
(, "\\SERVER\SHARE").
Path -

, "|", "}" "%-_.". . - "%2c", - "%7c", "}"


"%7d". "%" = "%25".
.
:
{drive:{src}}
{drive:c:\path\file}
{drive:\\server\share\path\file}
{groupname}
, . {group}
, .
{hwnd}
.
{wizardhwnd}
. '0', .
{ini:Filename,Section,Key|DefaultValue}
INI .
Filename - ini-,

Section -
Key -
DefaultValue - , ,

",", "|", "}" , "%- ".


"%2c", "|" - "%7c", "}" - "%7d". "%", "%25".
Filename, Section, Key .
:
{ini:{win}\MyProg.ini,Settings,Path|{pf}\My Program}
{language}
. [Languages].
{cm:MessageName}
{cm:MessageName,Arguments}

MessageName - , .
[CustomMessages]
Arguments - ,

",", "|", "}" , "%- ".


"%2c", "|" - "%7c", "}" - "%7d". "%", "%25".
Arguments .
:
{cm:LaunchProgram,Inno Setup}
"Launch Inno Setup" , .
{reg:HKxx\SubkeyName,ValueName|DefaultValue}
.
HKxx - . [Registry]
SubkeyName -
ValueName - . = " ".
DefaultValue - , , (REG_SZ REG_EXPAND_SZ)

",", "|", "}" , "%- ".


"%2c", "|" - "%7c", "}" - "%7d". "%", "%25".
SubkeyName, ValueName, DefaultValue .
:

{reg:HKLM\Software\My Program,Path|{pf}\My Program}


{param:ParamName|DefaultValue}
.
ParamName -
DefaultValue - , .

",", "|", "}" , "%- ".


"%2c", "|" = "%7c", "}" = "%7d". "%", "%25"
ParamName DefaultValue .
:
{param:Path|{pf}\My Program}
c:\My Program "/Path=c:\My Program".
{srcexe}
, "C:\SETUP.EXE".
{sysuserinfoname}
{sysuserinfoorg}
. .
{uninstallexe}
, "C:\Program Files\My Program\unins000.exe".
[Icons] . , Uninstallable yes ( ).
{userinfoname}
{userinfoorg}
{userinfoserial}
, , (
UserInfoPage ). [Ini] [Registry],
.
{username}
, ( GetUserName).

4:
:
"Setup"
, , . ,, .
Ctrl+F9
C:\Users\< >\Documents\Inno Setup Examples Output

5: ! ( SFX )
AutoIt v3 - , BASIC.

Windows GUI ( MS Windows).


,
- ,
.
, " " ,
(, VBScript SendKeys) .
AutoIt " " .

"" , .
SciTE Script Editor

:
;
If WinExists(@ScriptName) Then Exit
AutoItWinSetTitle(@ScriptName)
;
FileInstall("C:\Users\< >\Documents\Inno Setup Examples Output\setup.exe (
, ) ", "C:\Windows\Temp\< >.exe")
;
RunWait('C:\Windows\Temp\< >.exe /< >')
( )

/VERYSILENT /SILENT
Exit
:

;
If WinExists(@ScriptName) Then Exit
AutoItWinSetTitle(@ScriptName)
;
FileInstall("C:\Users\< >\Documents\Inno Setup Examples Output\setup.exe
(
, ) ",
"C:\Windows\Temp\< >.exe")
;
RunWait('C:\Windows\Temp\< >.exe /VERYSILENT')
Sleep(80)
;
FileDelete("C:\Windows\Temp\< >.exe")

"Compile Script to .exe" exe .


( ) -
( - )

Вам также может понравиться