Jump to content
Sign in to follow this  
dannyict

Readme and program window not closing

Recommended Posts

dannyict

Hi, I am trying to close the readme.txt and the programgroup window of Mindman Personal after installation (http://www.gr8ict.com/downloads/mmpersonal30-2e.exe)

However it won't work...am also new at this and yes i checked the manual

here's the code

;Mindman Personal
Run("mmpersonal30-2e.exe")
Do
    Sleep (1500)
    If Winexists("MindMan Personal - Setup", "Welcome to the MindMan") Then
        $w = 1
        WinActivate("MindMan Personal - Setup", "Welcome to the MindMan")
    EndIf
Until $w = 1
;WinWaitActive("MindMan Personal - Setup", "Welcome to the MindMan")
Send("{ENTER}")
WinWaitActive("MindMan Personal - Setup", "Please read the following")
Send("{ENTER}")
WinWaitActive("MindMan Personal - Setup", "You may use")
Send("{ENTER}")
WinWaitActive("MindMan Personal - Setup", "To specify a different")
Send("{ENTER}")
WinWaitActive("MindMan Personal - Setup", "Program icon folder")
Send("{TAB}")
Send("{TAB}")
Send("{TAB}")
Send("{ENTER}")
WinWaitActive("MindMan Personal - Setup", "Setup Wizard now has enough")
Send("{ENTER}")
WinWaitActive("MindMan Personal - Setup", "the MindMan Team hopes")
Send("{ENTER}")
WinWaitActive("MindMan Personal - Setup", "MindMan Personal was successfully")
Send("{ENTER}")
;Send("!c")
WinWaitActive("MindMan Personal" , "FolderView")
Send("!+{F4}",0)
WinWaitActive("README - Kladblok" , "MindMan Personal - Take fast track to high performance")
Send("!+{F4}",0)

what am i doing wrong? Anyone can help?

Share this post


Link to post
Share on other sites
monoscout999

You can try winclose() or edit this from the code

Send("!{F4}") because you dont need the +, that is shift key.

Edited by monoscout999

Share this post


Link to post
Share on other sites
dannyict

thanks, tried that Winclose and even Winkill, still the same. With Send("!{F4}") still the same.

Very strange.

Edited by dannyict

Share this post


Link to post
Share on other sites
wakillon

Add #AutoIt3Wrapper_Run_Debug_Mode=Y

Run you script and look at the console

you will find where it blocks.


AutoIt 3.3.14.2 X86 - SciTE 3.6.0WIN 8.1 X64 - Other Example Scripts

Share this post


Link to post
Share on other sites
dannyict

thanks for the reply, did not get anything

Share this post


Link to post
Share on other sites
monoscout999

post the Scite console output after that.

Edited by monoscout999

Share this post


Link to post
Share on other sites
dannyict

post the Scite console output after that.

Sorry am a bit lost here, where do I see the errors or how do I get that console output?

Thanks for the effort people, still much to learn :mellow:

Edited by dannyict

Share this post


Link to post
Share on other sites
monoscout999

Are you using SciTe?, the console is the part of avobe.

Run your script from scite, don`t compile it

Share this post


Link to post
Share on other sites
wakillon

Sorry am a bit lost here, where do I see the errors or how do I get that console output?

Thanks for the effort people, still much to learn :mellow:

The console is at the bottom of the SciTE editor.


AutoIt 3.3.14.2 X86 - SciTE 3.6.0WIN 8.1 X64 - Other Example Scripts

Share this post


Link to post
Share on other sites
dannyict

all I get is error=0

Share this post


Link to post
Share on other sites
monoscout999

all I get is error=0

That is not usefull.. please try to do the things the a more effective and informative way

The console have mora lines a lot of more lines... COPY ALL and PASTE IT HERE BETWEEN A CODE TAGS

You shoulg ghet a lot of error=? because you have many lines...

You also have to ensure that the script run for the first line to the end, this only will happen if you intall the mindman again in your PC, because maybe you will have problems whit the winwait... commands, WE NEED THAT THE SCRIPT RUN AS YOU WERE INSTALLING THE PROGRAM.

1. UnInstall the program(If you don`t need it in that PC(or use a PC that don`t have the PC Installed).

2. Open the Au3 File in SciTE.

3. Add the line #AutoIt3Wrapper_Run_Debug_Mode=Y at the top of the script(you need it only once).

4. Run the script.

5. when the script idles or it closes select the WHOLE CONSOLE and copy all the text inside.

6. Start to post here and add and between that paste your code.

Share this post


Link to post
Share on other sites
dannyict

Sorry, installed the SciTe editor again and now I get more

>"C:\Program Files (x86)\AutoIt3\SciTE\AutoIt3Wrapper\AutoIt3Wrapper.exe" /run /prod /ErrorStdOut /in "C:\brol\mindmappersonal.au3" /autoit3dir "C:\Program Files (x86)\AutoIt3" /UserParams    
+>20:13:46 Starting AutoIt3Wrapper v.2.0.3.0    Environment(Language:0413  Keyboard:00000813  OS:WIN_7/Service Pack 1  CPU:X64 OS:X64)
>Running AU3Check (1.54.19.0)  from:C:\Program Files (x86)\AutoIt3
+>20:13:46 AU3Check ended.rc:0
>Running:(3.3.6.1):C:\Program Files (x86)\AutoIt3\autoit3_x64.exe "C:\brol\mindmappersonal.au3"    
!> Starting in DebugMode..
Line: @error-@extended: Line syntax
0001: 0-0: #AutoIt3Wrapper_Run_Debug_Mode=Y
0003: 0-0: Run("mmpersonal30-2e.exe")
0004: 0-0: $w = 0
0005: 0-0: Do
0006: 0-0:     Sleep (1500)
0007: 0-0:     If Winexists("MindMan Personal - Setup", "Welcome to the MindMan") Then
0008: 0-0:         $w = 1
0009: 0-0:         WinActivate("MindMan Personal - Setup", "Welcome to the MindMan")
0010: 0-1:     EndIf
0011: 0-1: Until $w = 1
0013: 0-1: Send("{ENTER}")
0014: 0-0: WinWaitActive("MindMan Personal - Setup", "Please read the following")
0015: 0-0: Send("{ENTER}")
0016: 0-0: WinWaitActive("MindMan Personal - Setup", "You may use")
0017: 0-0: Send("{ENTER}")
0018: 0-0: WinWaitActive("MindMan Personal - Setup", "To specify a different")
0019: 0-0: Send("{ENTER}")
0020: 0-0: WinWaitActive("MindMan Personal - Setup", "Program icon folder")
0021: 0-0: Send("{TAB}")
0022: 0-0: Send("{TAB}")
0023: 0-0: Send("{TAB}")
0024: 0-0: Send("{ENTER}")
0025: 0-0: WinWaitActive("MindMan Personal - Setup", "Setup Wizard now has enough")
0026: 0-0: Send("{ENTER}")
0027: 0-0: WinWaitActive("MindMan Personal - Setup", "the MindMan Team hopes")
0028: 0-0: Send("{ENTER}")
0029: 0-0: WinWaitActive("MindMan Personal - Setup", "MindMan Personal was successfully")
0030: 0-0: Send("{ENTER}")
0031: 0-0: WinWaitActive("MindMan Personal")
0032: 0-0: Send("!{F4}",0)
0033: 0-0: WinWaitActive("README.TXT - Kladblok")

then it stops until I click on the readme.txt and then it finishes

Edited by dannyict

Share this post


Link to post
Share on other sites
Jos

WinWaitActive() means it waits until the window becomes active meaning Get the Focus, which is what happens when you click it?

Use WinWait() if you don't want ti wait until Kladblok(NotePad) gets the focus.

Jos

Edited by Jos

Visit the SciTE4AutoIt3 Download page for the latest versions  - Beta files                                How to post scriptsource        Forum Rules
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Share this post


Link to post
Share on other sites
wakillon

0032: 0-0: Send("!{F4}",0)

0033: 0-0: WinWaitActive("README.TXT - Kladblok")

Console indicate 2 possibilities Send("!{F4}",0) don't work or WinWaitActive("README.TXT - Kladblok") wait indefinitively because bad title !

Now you know where searching your error !


AutoIt 3.3.14.2 X86 - SciTE 3.6.0WIN 8.1 X64 - Other Example Scripts

Share this post


Link to post
Share on other sites
dannyict

Thanks for all the advice and the lessons :mellow:. Got it fixed.

Share this post


Link to post
Share on other sites
somdcomputerguy

Thanks for all the advice and the lessons :mellow:. Got it fixed.

Please post how you resolved this issue. It just may help another that has a similar problem.


- Bruce /*somdcomputerguy */  If you change the way you look at things, the things you look at change.

Share this post


Link to post
Share on other sites
dannyict

Well I used WPI in the first place for a series of programs to install, So I just split (probably not the most elegant way)

Fist part

Run("mmpersonal30-2e.exe")
$w = 0
Do
    Sleep (1500)
    If Winexists("MindMan Personal - Setup", "Welcome to the MindMan") Then
        $w = 1
        WinActivate("MindMan Personal - Setup", "Welcome to the MindMan")
    EndIf
Until $w = 1
;WinWaitActive("MindMan Personal - Setup", "Welcome to the MindMan")
Send("{ENTER}")
WinWaitActive("MindMan Personal - Setup", "Please read the following")
Send("{ENTER}")
WinWaitActive("MindMan Personal - Setup", "You may use")
Send("{ENTER}")
WinWaitActive("MindMan Personal - Setup", "To specify a different")
Send("{ENTER}")
WinWaitActive("MindMan Personal - Setup", "Program icon folder")
Send("{TAB}")
Send("{TAB}")
Send("{TAB}")
Send("{ENTER}")
WinWaitActive("MindMan Personal - Setup", "Setup Wizard now has enough")
Send("{ENTER}")
WinWaitActive("MindMan Personal - Setup", "the MindMan Team hopes")
Send("{ENTER}")
WinWaitActive("MindMan Personal - Setup", "MindMan Personal was successfully")
Send("{ENTER}")

then it goes to part 2

WinWaitActive("MindMan Personal")
Send("!{F4}",0)
WinWaitActive("README")
Send("!{F4}",0)

It works

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  

×