Questions tagged [healthkit]

HealthKit is a framework for iOS and watchOS that allows health and fitness services to share their data with the new Health app and with each other.

HealthKit allows apps that provide health and fitness services to share their data with the new Health app and with each other. A user’s health information is stored in a centralized and secure location and the user decides which data should be shared with your app.

HealthKit also works directly with health and fitness devices. In iOS 8.0, the system can automatically save data from compatible Bluetooth LE heart rate monitors directly into the HealthKit store. The system can also automatically import step count data from the M7 motion coprocessor, if available. Other devices and data sources must have a companion app that can access the data and save it to HealthKit for them.

Quick Reference:

1188 questions
-1
votes
1 answer

Shared HealthKit integration in Xcode for iOS and WatchOS

maybe you can help me with the following topic: I have developed an iOS app with HealthKit integration. All access rights to HealthKit are set up in the info.plist file. I wanted to integrate also a watchOS part into the same project as a…
-1
votes
1 answer

Workout session causing app crashes with multiple paired Apple Watches

Problem I am developing an application that can track workout sessions for multiple paired Apple Watches (multiple watches paired to a single phone). I have implemented Watch Connectivity for multiple watches as per Apple Documentation, and that…
-1
votes
1 answer

Get all wearable data from healthkit

I want to get step count from wearable devices such as samsung gear fit bit etc from the healthkit api. I want to know if it is possible to get data of all the wearables from the healthkit itself.
Abhishek Master
  • 192
  • 2
  • 19
-1
votes
1 answer

how to open next page (group page) from button in watchkit

I need to slide to next page(page2) what i need from button(page1) as attached image could you advice me ? Thanks you. main code //-------------- open group page ---------------// WKInterfaceController.reloadRootControllers( …
-1
votes
1 answer

Get total steps today

I am trying to make my app show the total of steps I have done today. According to by Health-Kit app on my phone I have done 6 steps, but the app tells me 0. This is the full code I am using: import UIKit import HealthKit class ViewController:…
-1
votes
1 answer

How can one use startWatchApp() while the parent iPhone app is in the background?

How can somebody open an Apple Watch app using Swift, assuming the parent iPhone app is running in the background, without getting the below error? Error Domain=com.apple.healthkit Code=550 "Cannot start watch app when phone app is in background"…
user1585762
  • 59
  • 1
  • 6
-1
votes
1 answer

Calculation of calories from HKHealthStore energy burned query

I am working on collecting active energy burned samples from HKHealthStore (Apple Watch device). Does anybody know how exactly is the active energy burned calculated here? I guess it's from type of activity, duration and heart beat. Are also…
rgreso
  • 496
  • 1
  • 7
  • 19
-1
votes
1 answer

The number 0 is being returned every time in HealthKit using swift?

I have been successfully able to write to HealthKit but receiving these values always return 0. I am trying to return the latest value of weight. This is the function that I read weight: public func readWeight(result: @escaping (Double) -> Void) { …
arodebaugh
  • 538
  • 1
  • 8
  • 26
-1
votes
2 answers

Swift 3: Calling Step Count Query from Health Kit

Updated: I am trying to call on a function that accesses the HealthKit and returns the number of steps taken that day. I have created a function and now I am trying to call it. The code for the function is as follows: //Reading data from Health…
user3546200
  • 269
  • 1
  • 3
  • 10
-1
votes
1 answer

Display the last heartrate which is saved in Healthkit with swift

I am building an App in Swift for a IOS App. I just want to display the last saved heartrate of the Healthkit. Can someone help me here? my Authorization request: static func authorizeHealthKit() { let HeartRateData: Set = [ …
-1
votes
1 answer

Format HKBiologicalSex object returned by healthkit to NSString

NSLog(@"gender %@", [[GSHealthKitManager sharedManager] readGender]); The function as defined in GSHealthKitManager.m file - (NSString *)readGender { NSError *error; NSString *gender=[self.healthStore biologicalSexWithError:&error]; …
Md. Ibrahim Hassan
  • 5,359
  • 1
  • 25
  • 45
-1
votes
2 answers

How do i write Blood Type in Health kit in iOS

I have a HKHealthStore object properly set up, and I am now trying to write user characteristics (i.e Date of Birth, Biological Sex, Blood Type and Fitzpatrick Skin Type). I can’t find that type in HKQuantityTypeForIdentifier. How do I write blood…
satya
  • 241
  • 3
  • 11
-1
votes
1 answer

how to save the blood pressure data in health kit app in iOS

Here is the saving blood pressure data in health kit. - (void)viewDidLoad { Systolic = 120; Diastolic = 90; [[GSHealthKitManager sharedManager]saveBloodPressureIntoHealthStore:Systolic Dysbp:Diastolic]; } -…
satya
  • 241
  • 3
  • 11
-1
votes
1 answer

using objective-c how to calculate Body Mass index and Body Fat Percentage in health kit

In my application I am integrating health kit framework. My project requirement is I want to push body fat percentage and Lean body mass values from my application to Health kit application. So I am writing like this. -(void)viewDidLoad { NSString…
satya
  • 241
  • 3
  • 11
-1
votes
1 answer

multiple thread in assembly language

override func viewDidLoad() { super.viewDidLoad() // Do any additional setup after loading the view, typically from a nib. //*********************************************************************************************************** …