Post not yet marked as solved
Hello,
I have class file, which should save data coreData and Im only able to save data via ui.
Do you have any example, how can I save data in core data via class files?
Greeting Fabian
Post not yet marked as solved
Hello,
I have RouteManage, which is a Class and has following Protokolls:
NSObject, Codable ,ObservableObject and is an Singleton
and I have a RouteTrackingAttributes which has ActivityAttributes
I tried to set
let attributes = RouteTrackingAttributes()
let state = RouteTrackingAttributes.ContentState(routeManager: routeManger)
activity = try? Activity.request()
the update from singleton. But it dosen't work. It worked only once?
thank you for help
greeting Fabian
Hello
i have build my own dialogue a normal hstack vstack its working not in scrollview and I have two Problems and no idea:
at fresh loading page or scroll at scroll view the dialogue is showing. by the second tap not :(
the ingoresafeplaces doesn't work.
do you have an solution?
Greeting Fabian
i have a save function:
func save(){
if let encoded = try? JSONEncoder().encode(routes) {
UserDefaults.standard.set(encoded, forKey: saveKey)
}
}
and an init function:
init() {
if let data = UserDefaults.standard.data(forKey: saveKey){
print(data.base64EncodedString)
if let decoded = try? JSONDecoder().decode([RouteObject].self, from: data) {
routes = decoded
return
}
}
routes = []
}
onload this initiation there is no data. but 3382 bytes
how get I the content form data?
i don't know where the error is?
debug is not possible I did get the info
Post not yet marked as solved
Hello,
I created an object which is inheriting from CLLocation.
The main cause is that I want to store more properties
Moreover I override the init function:
override init(latitude: CLLocationDegrees, longitude: CLLocationDegrees) {
super.init(latitude: latitude, longitude: longitude)
}
The objects aren't nil?
Can anyone help
Greeting Fabian
Post not yet marked as solved
Hi
I've got a problem with saving data in CoreData.
My Entity has a name und an UUID. Moreover I will this object create and save in a manager class with out access a ui.
this massage was I get : "Accessing Environment's value outside of being installed on a View. This will always read the default value and will not update."
Do you have a solution?
Greeting
Post not yet marked as solved
I trying to save the height from apple HealthKit in variables but it is only 0.0
Moreover I get the height in the result handler but I can't save it to the var.
Do you have any ideas?
greeting Fabian
Post not yet marked as solved
Hello Everyone,
I have Xcode 13.4.1 and iPhone 13 with iOS version 15.6.1
At the step to deployment to my iPhone I get an error:
This operation can fail if the version of the OS on the device is incompatible with the installed version of Xcode. You may also need to restart your mac and device in order to correctly detect compatibility.
Do you have any ideas?
Greeting Fabian