如何从 Office 内容添加中打开选择数据对话框。打开时打开的相同对话框
问问题
54 次
1 回答
0
最后我找到了答案
Office.context.document.bindings.addFromPromptAsync做的伎俩
Office.context.document.bindings.addFromPromptAsync(Office.BindingType.Table,
{
id: "you id",
promptText: "your text"
},
function (asyncResult) {
if (asyncResult.status == Office.AsyncResultStatus.Succeeded) {
if (asyncResult.value.columnCount < 2 || asyncResult.value.rowCount < 1) {
Office.context.document.bindings.releaseByIdAsync("DetailData");
myMessageBox.showErrorMessage("Insufficient detail data.");
}
else {
_detailDataBinding = asyncResult.value;
//do your work
}
}
});
于 2016-12-06T07:44:57.230 回答