I'm using InDesign CS5
I have the line of code:
this.Document.pages.appliedMaster = this.Document.masterSpreads.itemByName('myName');
When running, I get the error: "Invalid value for set property 'appliedMaster'. Expected MasterSpread or NothingEnum enumerator, but received nothing."
I looked up the classes and I can't detect any error.
This error will show up if there is no master spread called "myName"
Is myName a variable? Then remove the quotes around it.