Sign in to follow this  
Followers 0
MadzKeen

Help finishing off my first script - installation script

2 posts in this topic

I'm starting to get a hang of this, but I still need alot of help. I don't have a good grasp of scripting yet, so my codeing might look really off. I just need a little direction, I've been banging my head on the wall with no luck. The information on what I'm trying to do is below, any direction would great! I need to know if my logic is right and what commands I should be reading about to accomplish what I'm trying to get done. (They need to put a crying Icon on this form..)

Here is what my script is surpose to do:

Purpose:

Upgrade client when the user logs into the domain if it already hasn't been updated. (Note: EVRSI.sys is a legacy file that causes issues and is not use. That's why I'm just deleting it.)

Flow:

Check to see if "EVRSI.sys" exist --> if it does exist then stop "All Rockwell Services" --> delete the "EVRSI.sys" file --> Restart Workstation

Else

Check to see if application file exist --> if it does exist then end script

Else

Run "Install App Module"

EndIF

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

'Check if the EVRSI.sys file exist --> if it does then stop all rockwell services --> delete file --> then restart the workstation automatically

If FileExists("c:\evrsi.sys") Then

("All Rockwell Services")Stop_Service

FileDelete("c:\evrsi.sys")

"Restart Workstation"

Elseif FileExists("C:\Windows\Program Files\Rockwell Software\Factory Talk Activation\ftactTool.exe") Then

EndIf

Else

' Factory Talk Activation Installation Module

' Load the execution file

FileInstall("C:\Rockwell Software\3.02 Client\setup.exe", "C:\")

'Step through the Installation Wizard

WinActive("Install Wizard") Controlsend({Enter})

Winactive("Windows2") Controlsend({Enter})

WinActive("Window3") Controlsend({Enter})

Winactive("Windows4") Controlsend({Enter})

WinActive("Window5") Controlsend({Enter})

Winactive("Windows6") Controlsend({Enter})

WinActive("Windows7") Controlsend({Enter})

Winactive("Windows8") Controlsend({Enter})

WinActive("Window9") Controlsend({Enter})

Winactive("Window10") Controlsend({Enter})

WinActive("Window11") Controlsend({Enter})

Winactive("Window12") Controlsend({Enter})

' Configure the license client to point to fileserver1

Call "C:\Program Files\Rockwell Software\Factory Talk License Client\ftuLic.exe"

Winactive("Factory Talk License Client") Controlclick("Factory Talk License Client", "Settings TAB", Click "Add", "@fileserver1")

Controlsend({Alt+E})

"Restart Workstation"

EndIf

Share this post


Link to post
Share on other sites



#2 ·  Posted (edited)

Check to see if "EVRSI.sys" exist --> if it does exist then stop "All Rockwell Services" --> delete the "EVRSI.sys" file --> Restart Workstation

Else

Check to see if application file exist --> if it does exist then end script

Else

Run "Install App Module"

EndIF

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

'Check if the EVRSI.sys file exist --> if it does then stop all rockwell services --> delete file --> then restart the workstation automatically

If FileExists("c:\evrsi.sys") Then

("All Rockwell Services")Stop_Service

FileDelete("c:\evrsi.sys")

"Restart Workstation"

Elseif FileExists("C:\Windows\Program Files\Rockwell Software\Factory Talk Activation\ftactTool.exe") Then

EndIf

Ive already resolved this part from your other topic :)

;' Factory Talk Activation Installation Module
;' Load the execution file
FileInstall("C:\Rockwell Software\3.02 Client\setup.exe", "C:\") 
;'Step through the Installation Wizard 
WinActive("Install Wizard")
Send("{ENTER}")
Winactive("Windows2")
Send("{ENTER}")
WinActive("Window3")
;etc .....
;' Configure the license client to point to fileserver1
ShellExecute("C:\Program Files\Rockwell Software\Factory Talk License Client\ftuLic.exe") 
Winactive("Factory Talk License Client")
Controlclick("Factory Talk License Client", "", ID, 1) ;you need to get id with au3info tool
Send("!E")
;"Restart Workstation"

Now use helpfile for get more info about functions (F1 in SciTE)

Cheers, FireFox.

Edited by FireFox

 

OS : Win XP SP2 (32 bits) / Win 7 SP1 (64 bits) / Win 8 (64 bits) | Autoit version: latest stable / beta.
Hardware : Intel(R) Core(TM) i5-2400 CPU @ 3.10Ghz / 8 GiB RAM DDR3.

My UDFs : Skype UDF | TrayIconEx UDF | GUI Panel UDF | Excel XML UDF | Is_Pressed_UDF

My Projects : YouTube Multi-downloader | FTP Easy-UP | Lock'n | WinKill | AVICapture | Skype TM | Tap Maker | ShellNew | Scriptner | Const Replacer | FT_Pocket | Chrome theme maker

My Examples : Capture toolIP Camera | Crosshair | Draw Captured Region | Picture Screensaver | Jscreenfix | Drivetemp | Picture viewer

My Snippets : Basic TCP | Systray_GetIconIndex | Intercept End task | Winpcap various | Advanced HotKeySet | Transparent Edit control

 

Share this post


Link to post
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
Sign in to follow this  
Followers 0