共用方式為


PackageExtensionCatalog.PackageUninstalling 事件

定義

卸載擴充功能套件時引發的事件。

// Register
event_token PackageUninstalling(TypedEventHandler<PackageExtensionCatalog, PackageExtensionPackageUninstallingEventArgs const&> const& handler) const;

// Revoke with event_token
void PackageUninstalling(event_token const* cookie) const;

// Revoke with event_revoker
PackageExtensionCatalog::PackageUninstalling_revoker PackageUninstalling(auto_revoke_t, TypedEventHandler<PackageExtensionCatalog, PackageExtensionPackageUninstallingEventArgs const&> const& handler) const;
public event TypedEventHandler<PackageExtensionCatalog,PackageExtensionPackageUninstallingEventArgs> PackageUninstalling;
function onPackageUninstalling(eventArgs) { /* Your code */ }
packageExtensionCatalog.addEventListener("packageuninstalling", onPackageUninstalling);
packageExtensionCatalog.removeEventListener("packageuninstalling", onPackageUninstalling);
- or -
packageExtensionCatalog.onpackageuninstalling = onPackageUninstalling;
Public Custom Event PackageUninstalling As TypedEventHandler(Of PackageExtensionCatalog, PackageExtensionPackageUninstallingEventArgs) 

事件類型

備註

更新您處理此事件時所追蹤的延伸模組清單,以反映已卸載的擴充功能。 如果使用者重新安裝套件,則會引發 PackageInstalled 事件,而且您可以在處理該事件時重新新增擴充功能,就像新增任何擴充功能一樣。

如同 PackageUpdating,此事件只會傳遞正在卸載的套件,而不是 PackageExtensions的清單。

適用於

另請參閱