I can think of one workaround, although I admit that this is not the most elegant thing in the world.
For any worksheet for which you want to save the settings, first create a binding for "WorksheetName! A1: XFD1048576". You will get the identifier back, and this time it is unique and stored in the document
Office.context.document.bindings.addFromNamedItemAsync("WorksheetName!A1:XFD1048576", "matrix", function (result) {
if (result.status == 'succeeded'){
console.log('Added new binding with ID: ' + result.value.id);
}
else {
console.log('Error: ' + result.error.message);
}
});
Now create the settings based on this ID (or some mapping telling you Sheet1 = id AFD43243DDR3232 with the settings ____).
Does it help?
~ Mikhail Zlatkovsky, developer of the Office Extensibility team, MSFT
source
share