Now I using a Task with TNotificationCenter for Win 8, Win 10. The idea behind is to notify after finishing the task (load from large sqlite database), but the notification center shows an EOleException error as it says I am calling a marshalled interface from a thread...
Now I using a Task with TNotificationCenter for Win 8, Win 10. The idea behind is to notify after finishing the task (load from large sqlite database), but the notification center shows an EOleException error as it says I am calling a marshalled interface from a thread...
Is clever to start a timer and wait for the Task to finish with TTaskStatus.Completed and call the notification? I ask I am cannot think in another more decent solution... for now, that is the way I am doing that, problem is that I need to check for each individual task into the timer.
Is clever to start a timer and wait for the Task to finish with TTaskStatus.Completed and call the notification? I ask I am cannot think in another more decent solution... for now, that is the way I am doing that, problem is that I need to check for each individual task into the timer.
http://rumah-oz.blogspot.com/2016/01/membuat.notifikasi.windows10.dengan.Delphi10.Seattle.html
ReplyDeleteYou can use the TThread Sychronized method to call TNotificationCenter methods from the main thread.
ReplyDeleteChristen Blom-Dahl Just forgot synchronized! Gonna make a try. Thank you
ReplyDelete