2
Dear friends, good morning!
I started seeing a tutorial to develop a simple app in Xamarin with Sqlite, but I have a problem, with an object that calls Dependencyservice, they always come null, and I’m not managing to find the solution.
Below is the source code:
Connection class:
Iconfig interface:
Problem:
My config object, is null, how do I adjust it? I read to add an attribute of [Assembly: Depencendy(typeof(xxxxx)]. I don’t understand about it, I don’t know what I need to go through in the typeof, if I pass my current class, or if I pass the Dependencyservice class.
I await answers.
Att.
Felipe Duarte
[assembly: Dependency(typeof(ConfigDb))]
Is an annotation that should be in the class(public class ConfigDb : IConfigDb)
specific to each platform. Your project is of the typexamarin forms
?– rubStackOverflow