Yes, because I did not want to stalk you with to many questions I posted it as a new item (also because it actually is a new item/question).
Well bottom line is, is this then the right code to use?
for (var i=0; i<this.numFields; i++) {
var f = this.getField(this.getNthFieldName(i));
if (f==null) continue;
f.readonly = true;
}
app.execMenuItem("SaveAs")
event.target.display = display.hidden;