I just ran into this one..
A newly created command object does not have the files member correctly set, it's "undefined" until AddFiles() or something has been called.
var mc = DOpus.Create.Command();
DOpus.Output("mc.files.count: " + mc.files.count);
//expected output:
//mc.files.count: 0
A temporary workaround is this, it inits the files member to 0 elements.
var newCommand = DOpus.Create.Command();
newCommand.AddFiles(DOpus.Create.Vector());
Thanks! o)