PackageManagerDebugSettings.SetContentGroupStateAsync 方法
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
多載
SetContentGroupStateAsync(Package, String, PackageContentGroupState) |
設定內容群組的預備狀態以進行偵錯。 |
SetContentGroupStateAsync(Package, String, PackageContentGroupState, Double) |
設定內容群組的預備狀態以進行偵錯。 |
SetContentGroupStateAsync(Package, String, PackageContentGroupState)
設定內容群組的預備狀態以進行偵錯。
public:
virtual IAsyncAction ^ SetContentGroupStateAsync(Package ^ package, Platform::String ^ contentGroupName, PackageContentGroupState state) = SetContentGroupStateAsync;
/// [Windows.Foundation.Metadata.Overload("SetContentGroupStateAsync")]
/// [Windows.Foundation.Metadata.RemoteAsync]
IAsyncAction SetContentGroupStateAsync(Package const& package, winrt::hstring const& contentGroupName, PackageContentGroupState const& state);
[Windows.Foundation.Metadata.Overload("SetContentGroupStateAsync")]
[Windows.Foundation.Metadata.RemoteAsync]
public IAsyncAction SetContentGroupStateAsync(Package package, string contentGroupName, PackageContentGroupState state);
function setContentGroupStateAsync(package, contentGroupName, state)
Public Function SetContentGroupStateAsync (package As Package, contentGroupName As String, state As PackageContentGroupState) As IAsyncAction
參數
- contentGroupName
-
String
Platform::String
winrt::hstring
內容組名。 應用程式註冊此 API 才能運作時,必須有 AppxContentGroupMap.xml。
傳回
傳回當狀態變更時完成的 IAsyncAction。
- 屬性
另請參閱
適用於
SetContentGroupStateAsync(Package, String, PackageContentGroupState, Double)
設定內容群組的預備狀態以進行偵錯。
public:
virtual IAsyncAction ^ SetContentGroupStateAsync(Package ^ package, Platform::String ^ contentGroupName, PackageContentGroupState state, double completionPercentage) = SetContentGroupStateAsync;
/// [Windows.Foundation.Metadata.Overload("SetContentGroupStateWithPercentageAsync")]
/// [Windows.Foundation.Metadata.RemoteAsync]
IAsyncAction SetContentGroupStateAsync(Package const& package, winrt::hstring const& contentGroupName, PackageContentGroupState const& state, double const& completionPercentage);
[Windows.Foundation.Metadata.Overload("SetContentGroupStateWithPercentageAsync")]
[Windows.Foundation.Metadata.RemoteAsync]
public IAsyncAction SetContentGroupStateAsync(Package package, string contentGroupName, PackageContentGroupState state, double completionPercentage);
function setContentGroupStateAsync(package, contentGroupName, state, completionPercentage)
Public Function SetContentGroupStateAsync (package As Package, contentGroupName As String, state As PackageContentGroupState, completionPercentage As Double) As IAsyncAction
參數
- contentGroupName
-
String
Platform::String
winrt::hstring
內容組名。 應用程式註冊此 API 才能運作時,必須有 AppxContentGroupMap.xml。
- completionPercentage
-
Double
double
模擬的安裝完成百分比。 介於 0 到 100.0 之間的值。 大於 100 的值會限制為 100。
傳回
傳回當狀態變更時完成的 IAsyncAction。
- 屬性
備註
無法變更 PackageContentGroup.RequiredGroupName) 所指定之必要內容群組 (的狀態。 如果指定這個群組,此方法將會失敗。