Trouble with sample code

Hi there, I’ve been trying to use Android Studio to get the sample code working (at this moment I am trying step diary) but there seems to be some trouble importing the classes from the .aar library, as in this block of code:

import com.samsung.android.sdk.healthdata.HealthConstants.StepCount
import com.samsung.android.sdk.healthdata.HealthConstants.StepDailyTrend
import com.samsung.android.sdk.healthdata.HealthDataResolver
import com.samsung.android.sdk.healthdata.HealthDataResolver.AggregateRequest
import com.samsung.android.sdk.healthdata.HealthDataResolver.AggregateRequest.AggregateFunction
import com.samsung.android.sdk.healthdata.HealthDataResolver.AggregateRequest.TimeGroupUnit
import com.samsung.android.sdk.healthdata.HealthDataResolver.Filter
import com.samsung.android.sdk.healthdata.HealthDataResolver.ReadRequest
import com.samsung.android.sdk.healthdata.HealthDataResolver.SortOrder
import com.samsung.android.sdk.healthdata.HealthDataStore
import com.samsung.android.sdk.healthdata.HealthDataUtil

sdk is highlighted red, and building returns the following error message: Kotlin: Unresolved reference: sdk

Any idea as how to fix this?

Edit: changing in Project Structure the resource folder for src.main/res leads to a new error message Module ‘samsung-health-android-sdk-sample-stepdiary-20201103’ production: java.lang.NoClassDefFoundError: com/android/resources/ResourceFolderType

Please help

An application that uses the SDK will work properly with Samsung Health after the partner app approval. Partnership with Samsung Health team is requires before using the SDK.

However Developer Partnerships are currently suspended. If you open a Developer Support Request they will put you on a list of people to notify once applications are being accepted.

Ron
Samsung Developer Team9h8

Thank you for your response, I understand. But does this also apply to the examples provided here (https://developer.samsung.com/health/android/sample/step-diary.html), under “samples”?

My understanding it it does the Health Programming Guide page is where I got

Partnership with Samsung Health team is requires before using the SDK

However, I’m not an expert on Health SDK. You should ask when you submit the tech support request.

Ron
Samsung Developer Program

I see, thank you very much