I have problems with the function _ScreenCapture_SaveImage().
It returns False and sets @error to 1, if the save operation was successful.
I believe the problem is in the last line:
$iResult = _GDIPlus_ImageSaveToFileEx($hImage, $sFileName, $sCLSID, $pParams) ... Return SetError($iResult, 0, $iResult = 0)
_GDIPlus_ImageSaveToFileEx returns True=successful; False = failure.
This return value is inverted and returned by _ScreenCapture_SaveImage.
I changed the code to:
Return SetError($iResult=False, 0, $iResult = True)
and now it seems to work fine.
Maybe there are other functions in ScreenCapture like this, but I didn't checked.
Kind regards,
Christian




