Closed biencuong closed 6 days ago
Here's the guide in English to set up the ContactsProvider class and ensure it works correctly:
Here's the guide in English to set up the ContactsProvider class and ensure it works correctly:
package com.goodwy.commons
import android.content.ContentProvider
import android.content.ContentValues
import android.database.Cursor
import android.net.Uri
class ContactsProvider : ContentProvider() {
override fun onCreate(): Boolean {
return true
}
override fun query(
uri: Uri,
projection: Array
<provider android:name="com.goodwy.commons.ContactsProvider" android:authorities="com.goodwy.commons.contactsprovider" android:exported="false" />
After completing these steps, try rebuilding and running the project. This should resolve issues with the ContactsProvider class, and the setup should now work correctly.
What version of the app do you have installed and what operating system is on your device? At what point do you receive an error message? Have you had this error before or is it caused by some action?
I am encountering an issue in my application and need your assistance. The error message I am seeing is: Failed to find provider info for com.goodwy.commons.contactsprovider I have ensured that I’ve correctly declared the ContentProvider in my AndroidManifest.xml file with the following configuration: <provider android:name="com.goodwy.commons.ContactsProvider" android:authorities="com.goodwy.commons.contactsprovider" android:exported="true" /> Despite this, the application is unable to find the provider. Could you please help me resolve this issue? I would appreciate any guidance on ensuring that the provider is correctly set up and accessible.
Thank you for your support.
Best regards,