If the condition was reversed, it could be done with a simple command, since the image converter will fit the image into the specified width and height if both are given.
But doing the opposite, so the smaller dimension is made a fixed size and the other dimension extends outside the width/height box will probably require a bit of scripting.
If scripting is already being used then it's also an easy way to add the prefix to the filename (via the Image command's AS argument).
We can help with that if needed, although we may be a bit slow for the next couple of weeks.