Page 1 of 1

Crash with Autoit script

Posted: Mon Jun 27, 2011 1:12 pm
by lian
Hello,
some strange problem. I use Autoit Scripts and one of them (not all) make MP crashes. The script is used to save images in Gimp and has nothing to do with MP but each time I use it, MP (in background) stops working.
Here is the code

Code: Select all

#Region ;**** Directives created by AutoIt3Wrapper_GUI ****
#AutoIt3Wrapper_outfile=E:\Lian\vrac\scriptsautoit\sauvegarde gimp-xz-2010.exe
#AutoIt3Wrapper_Res_Comment=http://www.hiddensoft.com/autoit3/compiled.html
#AutoIt3Wrapper_Res_Description=AutoIt v3 Compiled Script
#AutoIt3Wrapper_Run_AU3Check=n
#EndRegion ;**** Directives created by AutoIt3Wrapper_GUI ****
#Region converted Directives from E:\Lian\vrac\scriptsautoit\sauvegarde gimp-xz.au3.ini
#EndRegion converted Directives from E:\Lian\vrac\scriptsautoit\sauvegarde gimp-xz.au3.ini
;
#include <Date.au3>
AutoItSetOption ( "MouseCoordMode", 0 )
$jour=@MDAY
$mois=@MON
$an=@YEAR
Opt("WinTitleMatchMode", 2)
WinActivate("Calques","")
Sleep(300)
Send("^s")
Sleep(300)
Send("{ENTER}")
Sleep(300)
Send("^r")
Sleep(300)
WinActivate("Échelle et taille de l'image")
Sleep(300)
Send("^c")

$a = ClipGet ( )

Send("!h")
Send("^c")
$b = ClipGet ( )

If $a >= $b Then
	Send("!l")
	Send("800")

Else
	Send("!h")
	Send("850")
EndIf

Send("{ENTER}")
Send("!é")
Sleep(2000)
WinActivate("Calques","")

Send("^+s")
Sleep(200)
WinActivate("Enregistrer l'image")
Send("{END}")
Send("{BS 3}")
Send("jpg")
Send("{HOME}")
$chemin = "c:\images\"
ClipPut($chemin)
Send("^v")
Sleep(300)
Send("{ENTER}")
Sleep(500)
WinWaitActive("Exporter fichier")
WinActivate("Exporter fichier")
Sleep(300)
Send("{ENTER}")
WinWaitActive("Enregistrer en JPEG")
WinActivate("Enregistrer en JPEG")
Send("{ENTER}")



	Exit

Re: Crash with Autoit script

Posted: Mon Jun 27, 2011 2:48 pm
by xnview
MP is opened on same folder?

Re: Crash with Autoit script

Posted: Mon Jun 27, 2011 3:14 pm
by lian
Yes !

Re: Crash with Autoit script

Posted: Mon Jun 27, 2011 6:20 pm
by xnview
It's a known bug

Re: Crash with Autoit script

Posted: Mon Jun 27, 2011 9:31 pm
by lian
OK. I hope there will be a solution :-)