共用方式為


HKHealthStore.RequestAuthorizationToShareAsync(NSSet, NSSet) 方法

定義

要求自動設定以儲存和讀取使用者資料,並在決定之後執行動作。

public virtual System.Threading.Tasks.Task<Tuple<bool,Foundation.NSError>> RequestAuthorizationToShareAsync (Foundation.NSSet typesToShare, Foundation.NSSet typesToRead);
abstract member RequestAuthorizationToShareAsync : Foundation.NSSet * Foundation.NSSet -> System.Threading.Tasks.Task<bool * Foundation.NSError>
override this.RequestAuthorizationToShareAsync : Foundation.NSSet * Foundation.NSSet -> System.Threading.Tasks.Task<bool * Foundation.NSError>

參數

typesToShare
NSSet
typesToRead
NSSet

傳回

表示非同步 RequestAuthorizationToShare 作業的工作。 TResult 參數的值的類型為 System.Action < System.Boolean,Foundation.NSError > 。

適用於