Jump to content

Making silent installers as nLite addons- office07/corelx4


masky007
 Share

Recommended Posts

This is the guide that i followed:

master_mtz said:

hi all , i am making this little guide to help making autoit scripts , to avoid the troubles of finding switches and so on .....

==============================================

here we go .....

=============================================

-----------------------

what is an Autoit Script

------------------------

it is a simple script , made to do jobs automatically , u write down the script (the script is mainly a robot that will tell the system what to do ) , then compile it , the resulting exe will do what u specifed in the code each time the program runs,

----------------------------

What is the relation between Auto it and silent install:

---------------------------

simply , u wil make the installation go smoothly , without ur interaction , the script u make will do the job ..... u may see examples in this topic :

http://www.msfn.org/...showtopic=20197

---------------------

OHH dear , shall i write scripts and think of coding

----------------------

Answer is , NO , u will see in this guide , how will we make scripts for silent installs without writing code.

------------------------

Why and when shall i use autoit for silent install ?

------------------------

when u don't find the silent switch u need , u are pushed to use the autoit method ..

==============NOW LET US GOOO!!!!================

firstly we need the program ,,, get it here

http://www.autoitscr...it-v3-setup.exe

and we need the Scite tool , to use the script recorder::

Scite

---------

http://www.autoitscr...iTe4AutoIt3.exe

install both programs ,,,

now go to :

Start >>programs>>autoit V3>>scite>>Script Writer

u will see this :

Attachment scritptw.PNG

1- select the installation package which u r going to make the script for , it shall be an EXE which the script will call each time it runs ..........

2- make the check boxes , as made in the pic

3- click the "A" button

once we click the "A" button,the exe(which is the installation package) we specifed will run, and every movement we make on our pc using the keyboard will be recorded,

During the record of this code , Take care of :

1-Avoid Alt+tab, or navigating to othr windows

2- use " Alt+N" to choose "next" ، Alt+y to choose " Yes" , and so on ..

3- u may use the Tab button to navigate between buttons

After u completly installed the application , we have to stop the record operation by clicking the "A" button at the upper left of the screen , now u must see some code written like this ....

Attachment daemonsc.PNG

Now , we have to add little code to our app , to avoid hassles , and running same application again and again

-------------------------------------

$SF_1 = "app.exe"

If WinExists ( $SF_1 ) Then Exit

AutoItWinSetTitle ( $SF_1)

---------------------------------------

** u may ask , what is this attented for , the answer is , this code is just a safety measure during the testing period , i once used a script which don't have this code (or similiar) and a big trouble occourded , the compiled EXE kept running it self again and again , and at last , 101 process where running on my poor pc :no: , i used taskkill to

get rid of those processes and i succeded :thumbup

---------------------------------

replace app.exe by the installation package exe u selected when recording the script, now save the file near by ur EXE package as u see in the pic , then compile the script ....

Attachment compile.PNG

NOW all is done we have the compiled EXE , try running it now , u will see every thing in the setup going automatically

without ur interaction , once u test and find every thing working good , u may make a RARsfx which will have the compiled EXE to run after the extraction process

I found this useful when I cant find any silent switches for my installers :thumb_yello:

Attached thumbnail(s)

* Attached Image

* Attached Image

* Attached Image

---------------------------------------------------------------------------------------------------------------------

everything went good the first time... when i tried to install ifranviewr. but...

when i moved on the next stage to make a script for CorelDrawX4 i went into a trouble..

so this is what i am doing

first starting the scriptwriter

then rechecking the boxes as shown in the guide in the scriptwriter.

locating the setup.exe trough "browse"

and now i start the scriptwriter by pressing the A

the installation process begins.. and i am using alt+n alt+t etc. etc. after everything is done. i am stoping the scriptwriter by pressing the A again.. so the script should be complete now as i know..

if i put this code

$SF_1 = "app.exe"

If WinExists ( $SF_1 ) Then Exit
AutoItWinSetTitle ( $SF_1)

below the script should work right?

and allso dose the "app.exe" should be named as i name the script when i am saving it or like the setup which i am installint the program.. in my case setup.exe

ok lets move on... as i know this code is not a big problem.. but a pice of code to keep you out of problems :)

ok so i right click the scrip and than click compile.. the script is now compiled...

time to rock en roll but the string of the guitar here broked ;)\

when i start the compiled .exe file the installation begins the loadings are good and when it comes when it should accept alt+a (the first command )for the accepting the licence agreement actualy it stops.. here dose not do anything.

i also tried to make autoit installer for office 2007

everything is going fine.. the licence agreement.. the serial numbet.. and when it comes to the Install button .. the scrip it's not working B)((

for CorelX4 but here is what i noticed.. if i run the script again while the other is in progres (actualy where it stops before should make alt+a command) the script works. :S why is that..

please help..

and i have another question which is not realeted to the question above..

why when i save my script from the scripwriter it doesn't have the proper name as i name it.. instead of ex. scrip1.au3 it saves like some strange codes..

please for fast answer.. i need this

btw here is the script for CorelDrawX4

Opt("WinWaitDelay",100)
Opt("WinTitleMatchMode",4)
Opt("WinDetectHiddenText",1)
Opt("MouseCoordMode",0)
Run('C:\Users\XP Computing\Desktop\TESTS\setup.exe')
WinWait("CorelDRAW Graphics Suite X4","")
If Not WinActive("CorelDRAW Graphics Suite X4","") Then WinActivate("CorelDRAW Graphics Suite X4","")
WinWaitActive("CorelDRAW Graphics Suite X4","")
Send("{ALTDOWN}a{ALTUP}{ALTDOWN}n{ALTUP}{ALTDOWN}n{ALTUP}{ALTDOWN}nn{ALTUP}{TAB}{ALTDOWN}n{ALTUP}{ALTDOWN}i{ALTUP}")
WinWait("Dialog","Cancel")
If Not WinActive("Dialog","Cancel") Then WinActivate("Dialog","Cancel")
WinWaitActive("Dialog","Cancel")
Send("{ALTDOWN}c{ALTUP}{TAB}{TAB}{TAB}")
WinWait("CorelDRAW Graphics Suite X4","")
If Not WinActive("CorelDRAW Graphics Suite X4","") Then WinActivate("CorelDRAW Graphics Suite X4","")
WinWaitActive("CorelDRAW Graphics Suite X4","")
Send("{ALTDOWN}c{ALTUP}")
Link to comment
Share on other sites

This is the guide that i followed:

---------------------------------------------------------------------------------------------------------------------

everything went good the first time... when i tried to install ifranviewr. but...

when i moved on the next stage to make a script for CorelDrawX4 i went into a trouble..

so this is what i am doing

first starting the scriptwriter

then rechecking the boxes as shown in the guide in the scriptwriter.

locating the setup.exe trough "browse"

and now i start the scriptwriter by pressing the A

the installation process begins.. and i am using alt+n alt+t etc. etc. after everything is done. i am stoping the scriptwriter by pressing the A again.. so the script should be complete now as i know..

if i put this code

$SF_1 = "app.exe"

If WinExists ( $SF_1 ) Then Exit
AutoItWinSetTitle ( $SF_1)

below the script should work right?

and allso dose the "app.exe" should be named as i name the script when i am saving it or like the setup which i am installint the program.. in my case setup.exe

ok lets move on... as i know this code is not a big problem.. but a pice of code to keep you out of problems ;)

ok so i right click the scrip and than click compile.. the script is now compiled...

time to rock en roll but the string of the guitar here broked B)\

when i start the compiled .exe file the installation begins the loadings are good and when it comes when it should accept alt+a (the first command )for the accepting the licence agreement actualy it stops.. here dose not do anything.

i also tried to make autoit installer for office 2007

everything is going fine.. the licence agreement.. the serial numbet.. and when it comes to the Install button .. the scrip it's not working B)((

for CorelX4 but here is what i noticed.. if i run the script again while the other is in progres (actualy where it stops before should make alt+a command) the script works. :S why is that..

please help..

and i have another question which is not realeted to the question above..

why when i save my script from the scripwriter it doesn't have the proper name as i name it.. instead of ex. scrip1.au3 it saves like some strange codes..

please for fast answer.. i need this

btw here is the script for CorelDrawX4

Opt("WinWaitDelay",100)
Opt("WinTitleMatchMode",4)
Opt("WinDetectHiddenText",1)
Opt("MouseCoordMode",0)
Run('C:\Users\XP Computing\Desktop\TESTS\setup.exe')
WinWait("CorelDRAW Graphics Suite X4","")
If Not WinActive("CorelDRAW Graphics Suite X4","") Then WinActivate("CorelDRAW Graphics Suite X4","")
WinWaitActive("CorelDRAW Graphics Suite X4","")
Send("{ALTDOWN}a{ALTUP}{ALTDOWN}n{ALTUP}{ALTDOWN}n{ALTUP}{ALTDOWN}nn{ALTUP}{TAB}{ALTDOWN}n{ALTUP}{ALTDOWN}i{ALTUP}")
WinWait("Dialog","Cancel")
If Not WinActive("Dialog","Cancel") Then WinActivate("Dialog","Cancel")
WinWaitActive("Dialog","Cancel")
Send("{ALTDOWN}c{ALTUP}{TAB}{TAB}{TAB}")
WinWait("CorelDRAW Graphics Suite X4","")
If Not WinActive("CorelDRAW Graphics Suite X4","") Then WinActivate("CorelDRAW Graphics Suite X4","")
WinWaitActive("CorelDRAW Graphics Suite X4","")
Send("{ALTDOWN}c{ALTUP}")

:) What exactly is your question?

Correction. Scite does now save as .au3 automatically.

Edited by EndFunc
EndFuncAutoIt is the shiznit. I love it.
Link to comment
Share on other sites

no one understand what was my problem? :)

well. i have followed the tutorial that i quoated.

So when i try to make a script for office 2007 the script is not working as it should and i dont know why

here it is exactly what i am doing.. and i think i am doing it right..

------------------------------------

- i only use keyboard commands, as for clicking next i use alt+n to cycle trough buttons i use only tab etc..

1. i am starting the ScriptWriter i am uncheking the "record mouse" and checking the "record window text"

2. i am browsing to the installation .exe which is "setup.exe"

and now i am starting to make the script ( so here i am clicking the A in the left corner in the ScriptWriter)

The installation of the Microsoft Office 2007 popsup.

the first step is to accept agreement i think so here i use the keyboard command alt+a, the next is i think full install or custom install ( i am not sitting on my own pc so i don't know exactly what is the next step but it sholdnt be that much important) and at the end when i't come to install i use the command alt+i on the keyboard to start the installation.. so everything works now.. the program installs.. and at the very end i use alt+c to close the installation process.

the scripter records everything of this... and should work after i compile it.. but when i start the script everything is ok until it reaches the install button where i am clicking alt+i, here the script stops working and i dont't know why this is my problem and my question is how to slove that problem.

it's he same and with when i try to install corelDrawX4

for the corel stops when i need to click accept agreement or something (using the command alt+a)

please for help....

i am at work with 15 new computers every day that need to be formated and reinstalled with windows and alot of applications.. so i need all this to manage to make SILENT instalation and after that to embad this in nLite so when i install windows to install all of the programs whitout my interference...

thaks in advance...

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...