Excel.LinkedEntityDataDomainRefreshCompletedEventArgs interface
提供有关对象 LinkedEntityCellValue 已刷新的链接实体数据域的信息。
注解
Excel web 版不支持此接口。
使用方
示例
// Registers an event handler for the onRefreshCompleted event.
await Excel.run(async (context) => {
const dataDomains: Excel.LinkedEntityDataDomainCollection = context.workbook.linkedEntityDataDomains;
dataDomains.onRefreshCompleted.add(onLinkedEntityDomainRefreshed);
await context.sync();
});
async function onLinkedEntityDomainRefreshed(eventArgs: Excel.LinkedEntityDataDomainRefreshCompletedEventArgs): Promise<void> {
console.log(`Linked entity domain refreshed: ${eventArgs.id}`);
console.log(`Event type: ${eventArgs.type}`);
console.log(`Event source: ${eventArgs.source}`);
console.log(`Service ID: ${eventArgs.serviceId}`);
console.log(`Refresh status: ${eventArgs.refreshed}`);
console.log(`Refresh errors: ${eventArgs.errors}`);
}
属性
| errors | 获取在请求刷新 |
| id | 获取对象已刷新的链接实体数据域的 |
| refreshed |
|
| service |
获取对象已刷新的链接实体数据域 |
| source | 获取事件源。 有关详细信息,请参阅 |
| type | 获取事件的类型。 有关详细信息,请参阅 |
属性详细信息
errors
获取在请求刷新 LinkedEntityCellValue 链接实体数据域的对象期间遇到的任何错误。
errors?: string[];
属性值
string[]
注解
Excel web 版不支持此属性。
id
获取对象已刷新的链接实体数据域的 LinkedEntityCellValue ID。 此 ID 由 Office 加载项定义。此 ID 不适用于由服务数据提供程序(如必应或 Power BI)定义的链接实体数据域。
id?: string;
属性值
string
注解
Excel web 版不支持此属性。
refreshed
true如果LinkedEntityCellValue已成功刷新链接实体数据域的对象,则返回 ;否则返回 false。
refreshed: boolean;
属性值
boolean
注解
Excel web 版不支持此属性。
serviceId
获取对象已刷新的链接实体数据域 LinkedEntityCellValue 的服务 ID。
serviceId: number;
属性值
number
注解
Excel web 版不支持此属性。
source
获取事件源。 有关详细信息,请参阅 Excel.EventSource。
source: Excel.EventSource | "Local" | "Remote";
属性值
Excel.EventSource | "Local" | "Remote"
注解
Excel web 版不支持此属性。
type
获取事件的类型。 有关详细信息,请参阅 Excel.EventType。
type: "LinkedEntityDataDomainRefreshCompleted";
属性值
"LinkedEntityDataDomainRefreshCompleted"
注解
Excel web 版不支持此属性。