ChristopherTyler

Issue after compile

4 posts in this topic

I have created a script to install ccleaner but when i compile it it will not run the last part to finish.

 

#RequireAdmin
 
#region --- Au3Recorder generated code Start (v3.3.9.5 KeyboardLayout=00000409)  ---
 
#region --- Internal functions Au3Recorder Start ---
Func _Au3RecordSetup()
Opt('WinWaitDelay',100)
Opt('WinDetectHiddenText',1)
Opt('MouseCoordMode',0)
Local $aResult = DllCall('User32.dll', 'int', 'GetKeyboardLayoutNameW', 'wstr', '')
If $aResult[1] <> '00000409' Then
  MsgBox(64, 'Warning', 'Recording has been done under a different Keyboard layout' & @CRLF & '(00000409->' & $aResult[1] & ')')
EndIf
 
EndFunc
 
Func _WinWaitActivate($title,$text,$timeout=0)
WinWait($title,$text,$timeout)
If Not WinActive($title,$text) Then WinActivate($title,$text)
WinWaitActive($title,$text,$timeout)
EndFunc
 
_AU3RecordSetup()
#endregion --- Internal functions Au3Recorder End ---
 
 
Run('C:Installccsetup502.exe')
_WinWaitActivate("CCleaner v5.02 Setup","View license agreeme")
MouseClick("left",433,361,1)
_WinWaitActivate("CCleaner v5.02 Setup","Select any additiona")
MouseClick("left",251,238,1)
MouseClick("left",447,371,1)
_WinWaitActivate("CCleaner v5.02 Setup ","Completing the CClea")
MouseClick("left",189,176,1)
MouseClick("left",191,199,1)
MouseClick("left",443,364,1)
#endregion --- Au3Recorder generated code End ---
 
when running as script it will run the "Completing the cclea" section but after x86 compile it will not do this section 

Share this post


Link to post
Share on other sites



So how far does it get when compiled? Does it launch the first MsgBox? Does it run ccsetup502.exe? Does it do any of the mouseclicks? Instead of asking us to guess, please be very specific as to where it fails. Help us help you ;)


√-1 2^3 ∑ π, and it was delicious!

Share this post


Link to post
Share on other sites

hello ChristopherTyler, welcome to AutoIt and to the forum!

you'll find the common conception among automation experts would be that simulating mouse clicks and key press is the last resort, for various reasons.

this is strikingly true in your case, where:

1. CCleaner has command line parameters for setup

2. CCleaner is portable in nature - just copy the files over, and you're done.

all this does not in any way contradict the comment made by JLogan3o13. Read his last 4 words very carefully.

and finally, of course, >this.

Share this post


Link to post
Share on other sites

@ChristopherTyler -  Welcome to the forum.

Just for your interest, and others.

You should post your code using the provided code tags (see the button to the left of the Quote button).

It makes it easier for those trying to read and troubleshoot your code.

In fact, some won't even bother to help, if the code tags haven't been used.


AutoIt.4.Life Clubrooms - Life is like a Donut (secret key)

Make sure brain is in gear before opening mouth!
Remember, what is not said, can be just as important as what is said.

Spoiler

What is the Secret Key? Life is like a Donut

If I put effort into communication, I expect you to read properly & fully, or just not comment.
Ignoring those who try to divert conversation with irrelevancies.
If I'm intent on insulting you or being rude, I will be obvious, not ambiguous about it.
I'm only big and bad, to those who have an over-active imagination.

I may have the Artistic Liesense ;) to disagree with you. TheSaint's Toolbox (be advised many downloads are not working due to ISP screwup with my storage)

userbar.png

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