DERP! actual error thrown is "Object is invalid", not, "Object is invalidEngine".
A simple one (but don't feel bad, everyone including me falls for this one).
"place" does not return the object placed. Since you can place lots of items with a songle "place" command, it returns an *array*. (And guess its length if you place one single image.)
Derp me twice -- "songle" = "single".
that's what you get for typing on an iPad -- typo's and no "edit" function. (Which is Not Nice from the hosting forum, because Apple *also* uses Jive on its forum, and on theirs I *do* have iPad access to editing *as well as* the formatting buttons to add italic *et al* (hence my *star* emphasizing).)
OK, so, I modified my script as such,
var foobar = myDoc.pageItems[i].place(File("/foo/bar/baz/MyColoRectalScanInLivingC olor.jpg")); //! huzzah, it works.
and lo, rejoice. foobar is an array.
So I then tried: foobar.fit([yada yada]), but still the invalid Object error persists.
Am I daft, or, just drunk?
Nevermind. Total drunk-derp. I mispelled foobar.fit(FitOption).... ARHG.
JONGWARE, I tip my glass to you sir, this solved my problem.