I've got a *.dll that controls picture file dimensions. It consists of an easy function:

CopyPic (PChar: inFileName, outFileName: PChar, MaxSize: Int, MaxWidth: int, MaxHeight: int)

...and returns an int for error checking.

I have to can get on from PHP code. I'd it tell you Java.

In my opinion you've mixed everything up.

But anyway, have a look at

http://php.net/manual/en/function.system.php

http://support.microsoft.com/kb/164787

Check this out. Not used at all it but others have reported success...

EDIT You may also most likely get it done with .NET and/or COM although don't request me how...