I am having a very unique, but repeatable problem with ImageMagick COM interface. Here are the applicable lines of code:
$oIM=ObjCreate("ImageMagickObject.MagickImage.1")
and then later on...
$oIM.Convert(String($arFileList[$nFileIndex])&'[0]',"-alpha", "remove",@TempDir&"\temp.jpg")
the array points to a pdf file with the "convert" command converting the first page of the pdf to a jpg with any alpha layer removed.
Every time, without fail, the first time I run the script on a freshly booted machine it crashes on the $oIM.Convert command. It does this if it isn't compiled and says there is an error executing the command on the object. If compiled, i get an error that autoit has stopped responding. Anytime I run the script, compiled or not, after this initial crash everything works perfectly fine.
I am totally at a loss as to why this is occurring and how to correct it.