11-11-2020 06:11
11-11-2020 06:11
Hello! I am trying to make an app that has a tile list that has steps, calories, heart rate and floors as its items. I found how to add the steps, calories and the heart rate but I don't know how to add the floors. I've searched a lot and haven't found anything that works. I tried the following but it didn't work.
if (appbit.permissions.granted("access_activity")) {
if (goals.local.elevationGain !== undefined) {
popupText.text = `${goals.adjusted.elevationGain}`;
}
}
popupText.text is the text that I need the number of the floors to be. Does anyone have any ideas on how to do it? Thank youu!!
Answered! Go to the Best Answer.
11-11-2020 12:01
11-11-2020 12:01
Try just
goals.elevationGain
I know where you got goals.local from; I'll see if I can get that changed.
Also beware that some devices (eg, Versa Lite) don't support elevationGain.
11-11-2020 12:01
11-11-2020 12:01
Try just
goals.elevationGain
I know where you got goals.local from; I'll see if I can get that changed.
Also beware that some devices (eg, Versa Lite) don't support elevationGain.
11-12-2020 00:06
11-12-2020 00:06
Thank you for the response! It worked!