Показать полную графическую версию : Автоматическая установка Alcohol 120%, 52%
Страниц :
1
2
3
4
5
6
7
[
8]
9
10
katok888
12-04-2009, 14:11
hobbit25, вот пробуй, скачаешь- напиши, удалю файл.
"katok888, а можеш если не сложно скомпилированный выложить!"
А еще раз выложить ? или на фалообменник или закинь на почту пожалуйста.
vipnucleus
01-05-2009, 18:25
Я уже надеялся увидеть Alcohol 120%.198.7612, кстати всем спасибо за развитие данной статьи. Жалко шапка давно уже не обновляется
Ребят, я решил проблему с cкрытием окна cmd.exe.
Может кому-то пригодиться!
Какраз я использую это для установки Alcohol SFX- архива из раздела run реестра.
Чтобы не показалось странным, Runonce у меня не работает из-за замены explorer на другую оболочку.
Так что выход нашёлся даже с одним Run разделом. :)
Код для fasmW (flatassembler.net), очень легко скампилировать (F9) этот текст в бинарный файл Alcopexe.exe
include '%fasm%\win32ax.inc' ; C:\Program Files\Fasm\include\win32ax.inc
section '.code' code readable executable
invoke ShellExecute,\
NULL,\
NULL,\
lpFile,\
lpParameters,\
NULL,\
SW_HIDE
invoke ExitProcess,0
section '.data' data readable writeable
lpFile db 'cmd.exe',0
lpParameters db '/k start /w reg delete HKLM\Software\Microsoft\Windows\CurrentVersion\Run /v Alcopexe /f & %SystemRoot%\system32\Alcohol.exe & del /f /q %SystemRoot%\system32\Alcohol.exe & del /f /q %SystemRoot%\system32\Alcopexe.exe & Exit',0
data import
library kernel32,'KERNEL32.DLL',\
shell32,'SHELL32.DLL'
import kernel32,ExitProcess,'ExitProcess'
import shell32,ShellExecute,'ShellExecuteA'
end data
определение функции здесь
msdn.microsoft.com/en-us/library/bb762153(VS.85,printer).aspx
(если вдруг я ошибся)
Всмысле, установка %SystemRoot%\system32\Alcohol.exe (архива) запускается из раздела Run,
вызовом запускателя %SystemRoot%\system32\Alcopexe.exe, код которого выше,
переменная которого затем удаляется, и сам архив удаляется в завершении работы тоже.
SPTD.exe ставиться на t13 как обычно.
:)
mariolast
04-05-2009, 00:04
katok888,
Можешь еще раз свой скрипт выложить?
Скрипт скомпилированный (.exe) для Alcohol 120% 1.9.8.7612 выложите пожалуйста.
Вот, получайте, скрипт от katok888 подогнанный для Alcohol 120 1.9.8.7612.
Проверял на Windows XP и Windows 7.
#region - Alcohol.120.v1.9.8.7612 install script - (Automated with WinExists functions)
#include <IE.au3>
Opt('TrayIconDebug', 1)
; Installer.
$executable = 'Alcoholsetup.exe'
; Show progess.
$splash = 0
; Default catagory folder in startmenu.
$group = 'Alcohol 120%'
; New catagory to move the default folder into.
$catagory = ''
; Installation folder in Program Files.
$directory = 'Alcohol Soft\Alcohol 120'
; Allowed time for installation.
$allowed = 60 * 1000
; Components to choose. 1 = Yes, 0 = No.
$SecACID = 1 ; A.C.I.D Wizard
$langfiles = 1 ; Multi-Language Files
$manual = 1 ; Online manual
$shortcuts = 0 ; Desktop Shortcut
$startmenu = 1 ; Startmenu Entries
$starwind = 0 ; iSCSI Service
; ----- Settings Complete (Paste registration on line 83) ------
; Set components to install via registry.
$key = 'HKLM\SOFTWARE\Alcohol Soft\Alcohol 120%\AddRemove\Components'
RegWrite($key & '\SecACID', 'Installed', 'Reg_Dword', $SecACID)
RegWrite($key & '\SecLangFiles', 'Installed', 'Reg_Dword', $langfiles)
RegWrite($key & '\SecManual', 'Installed', 'Reg_Dword', $manual)
RegWrite($key & '\SecShortcuts', 'Installed', 'Reg_Dword', $shortcuts)
RegWrite($key & '\SecStartMenu', 'Installed', 'Reg_Dword', $startmenu)
RegWrite($key & '\SecStarWind', 'Installed', 'Reg_Dword', $starwind)
; Run the installer.
$pid = _Install()
$time = TimerInit()
$title = 'Alcohol 120%'
Do
Select
Case WinExists('Installer Language', 'Please select a language.')
ControlCommand('Installer Language','Please select a language.','ComboBox1',"SelectString",'English')
ControlClick('Installer Language', 'OK', 'Button1')
Case WinExists($title, 'Already Installed')
_Abort()
Case WinExists($title, 'Welcome to the Alcohol 120%')
WinMove($title, 'Welcome to the Alcohol 120%', @DesktopWidth, 0)
ControlClick($title, 'Welcome to the Alcohol 120%', 'Button2')
Case WinExists($title, 'License Agreement')
ControlClick($title, 'License Agreement', 'Button2')
Case WinExists('Alcohol Soft Setup', 'Additional Features and License Agreement')
WinMove('Alcohol Soft Setup', 'Additional Features and License Agreement', @DesktopWidth, 0)
Sleep(1000)
$oIE = _IEAttach ('Alcohol Soft Setup', 'embedded')
If IsObj($oIE) Then
$oSubmit = _IEGetObjByName ($oIE, "chk1")
If IsObj($oSubmit) Then
_IEAction ($oSubmit, "click")
EndIf
_IELoadWait ($oIE)
$oIE = 0
EndIf
ControlClick('Alcohol Soft Setup', 'Additional Features and License Agreement', 'Button2')
WinWaitClose('Alcohol Soft Setup', 'Additional Features and License Agreement', 1)
Case WinExists($title, 'Choose Components')
ControlClick($title, 'Choose Components', 'Button2')
Case WinExists($title, 'Choose Install Location')
ControlClick($title, 'Choose Install Location', 'Button2')
Case WinExists($title, 'Click Finish to close this wizard')
ControlCommand($title, 'Click Finish to close this wizard', 'Button4', 'UnCheck'); Run
ControlCommand($title, 'Click Finish to close this wizard', 'Button5', 'UnCheck'); Add Drive
ControlClick($title, 'Click Finish to close this wizard', 'Button2')
Case Else
Sleep(250)
EndSelect
If TimerDiff($time) > $allowed Then _Abort()
Until Not ProcessExists($pid)
; *** Paste Registration on the next line ***
; Exit if $startmenu = 0 from above.
If Not $startmenu Then Exit
; Remove shortcuts.
If _MainShortcut('Alcohol 120%.lnk') Then
FileDelete('Alcohol Command Launcher.lnk')
FileDelete('Alcohol Manual.lnk')
;~ FileDelete('Uninstall Alcohol 120%.lnk')
;~ _Desktop('Alcohol 120%.lnk')
EndIf
#endregion
Exit
Func _Install($path = Default)
; Run the installer in Default Script directory.
Dim $splash
If $path = Default Then $path = @ScriptDir
If StringRight($path, 1) <> '\' Then $path &= '\'
If StringInStr($executable, '\') Then $path = ''
If Not FileExists($path & $executable) Then Exit 1
If $splash Then _Splash('Installing:' & StringTrimRight(StringReplace(@ScriptName, '_', ' '), 4))
If StringRight($executable, 3) = 'msi' Then
Return Run('"' & @SystemDir & '\msiexec.exe" /i "' & $path & $executable & '"')
Else
Return Run('"' & $path & $executable & '"')
EndIf
EndFunc
Func _Abort()
; close process if exists then exit.
Dim $pid
If ProcessExists($pid) Then
ProcessClose($pid)
Exit 2
Else
Exit 3
EndIf
EndFunc
Func _Desktop($shortcut)
; Delete a Desktop shortcut.
If FileExists(@DesktopDir & '\' & $shortcut) Then
Return FileDelete(@DesktopDir & '\' & $shortcut)
ElseIf FileExists(@DesktopCommonDir & '\' & $shortcut) Then
Return FileDelete(@DesktopCommonDir & '\' & $shortcut)
EndIf
EndFunc
Func _MainShortcut($shortcut, $rename = '')
; Change working directory to correct StartMenu\Group directory.
Dim $group, $catagory, $splash
If $group = '' Then Return 0
If FileExists(@ProgramsDir & '\' & $group) Then
FileChangeDir(@ProgramsDir & '\' & $group)
ElseIf FileExists(@ProgramsCommonDir & '\' & $group) Then
FileChangeDir(@ProgramsCommonDir & '\' & $group)
Else
Return 0
EndIf
; Wait for main shortcut.
If $splash Then _Splash('Waiting for shortcuts')
For $i = 1 To 20
If FileExists($shortcut) Then ExitLoop
Sleep(500)
Next
If $splash Then _Splash('Cleaning up:' & StringTrimRight(StringReplace(@ScriptName, '_', ' '), 4))
; If catagory not assigned anything, then return.
If $catagory = '' Then Return 1
; Move the group folder into the catagory folder.
If FileChangeDir('..') And DirCopy($group, $catagory & '\' & $group, 1) Then
If DirRemove($group, 1) Then
; If optional rename parameter is used, then rename the group folder.
If $rename <> '' And FileChangeDir($catagory) Then
If DirCopy($group, $rename, 1) And DirRemove($group, 1) Then
Return FileChangeDir($rename)
EndIf
Else
Return FileChangeDir($catagory & '\' & $group)
EndIf
EndIf
EndIf
EndFunc
Func _QuickLaunch($shortcut)
; Delete a Quicklaunch shortcut.
Local $subdirs = '\Microsoft\Internet Explorer\Quick Launch'
If FileExists(@AppDataDir & $subdirs & '\' & $shortcut) Then
Return FileDelete(@AppDataDir & $subdirs & '\' & $shortcut)
ElseIf FileExists(@AppDataCommonDir & $subdirs & '\' & $shortcut) Then
Return FileDelete(@AppDataCommonDir & $subdirs & '\' & $shortcut)
EndIf
EndFunc
Func _Splash($text = '')
; Shows a small borderless splash message.
Dim $splash
If $splash Then
If $text Then
SplashTextOn('', $text, 500, 25, -1, 5, 1, '', 14)
Else
SplashOff()
EndIf
EndIf
EndFunc
Func _WinClose($title, $text = '')
; Close a window with further attempts.
For $i = 1 To 10
WinClose($title, $text)
If Not WinExists($title) Then Return 1
Sleep(500)
Next
EndFunc
Func OnAutoItStart()
; A 2nd script instance will exit.
Local $interpreter
$interpreter = StringTrimRight(@ScriptName, 4) & ' Script Interpreter'
If WinExists($interpreter) Then Exit
AutoItWinSetTitle($interpreter)
EndFunc
Удачи :smirk:
Вот, получайте, скрипт для Alcohol 120 1.9.8.7612 »
Спасибо конечно. Все работает. Скомпилировал.
Если чтото нужно, делай сам. Вот и мне пришлось разбираться с autoit.
Кому нужен скомпилированный в exe скрипт для Alcohol 120 1.9.8.7612, качайте по ссылке ниже.
http://ifolder.ru/12157673
vipnucleus
17-05-2009, 17:58
Кто - нибудь может дать ссылку на готовый файл, плиз.
Habetdin
17-05-2009, 23:13
ссылку на готовый файл »
На какой? Постом выше? :biggrin:
скомпилированный в exe скрипт для Alcohol 120 1.9.8.7612 »
vipnucleus
18-05-2009, 06:47
На версию Alcohol 120 1.9.8.7612, можно и постом выше.
vipnucleus, так и не понял, что ты хочешь.
Тихая установка Alcohol 120% 1.9.8.7612 (http://ifolder.ru/12172149) на основе скрипта autoit от katok888(Guru431)
Скрипт AutoIt для Alcohol 120% 1.9.8.7612 отдельно - здесь (http://ifolder.ru/12157673)
Вопросы регистрации каждый решает самостоятельно.
vipnucleus
18-05-2009, 20:00
Я так понял скрипт (а также "тихая установка") не предусматривают патч и активировать программу приходится в ручную?
Habetdin
18-05-2009, 20:06
vipnucleus, ОПК 3.18 (http://forum.oszone.net/rules.html#3.18) :butcher:
Подскажите как из командной строки полностью перенести папку Alcohol 120% из Documents and Settings\All Users\Главное меню\Программы в папку CD и DVD утилиты?
Пробовал использовать скрипты, но полностью перенести не удалось.
omich,
DirMove ( @ProgramsCommonDir & '\Alcohol 120%', @ProgramsCommonDir & '\CD и DVD утилиты\Alcohol 120%', 1 )
gvshil,
Спасибо! Сначало не пошло, но после чистки реестра все получилось.
Единственный минус - папка Alcohol 120% тоже осталась. Как ее удалить?
папка Alcohol 120% тоже осталась. Как ее удалить? »
Возможно, она прописана и в @ProgramsDir , тогда
DirRemove (@ProgramsDir & '\Alcohol 120%', 1)
gvshil,
Попробовал и не получилось.
Тогда дайте полный путь к папке Alcohol и ее полное имя (и папке для всех пользователей, и для вашего пользователя).
Да, на всякий случай, это для AutoIt я давал.
© OSzone.net 2001-2012
vBulletin v3.6.4, Copyright ©2000-2025, Jelsoft Enterprises Ltd.
Available in ZeroNet 1osznRoVratMCN3bFoFpR2pSV5c9z6sTC