Reputation: 742
I want to use this library into my android studio application https://github.com/dm77/barcodescanner. I followed the mentioned step like add library into build.gradle file and add jcenter() but still I have the error Could not find me.dm7.barcodescanner:zbar:1.9.13
.
What Am I missing?
Upvotes: 7
Views: 6929
Reputation: 4458
Use version 1.9.8
'me.dm7.barcodescanner:zxing:1.9.13'
Google "barcodescanner zxing maven" and the related maven library version is expected to appear. Like this:
https://mvnrepository.com/artifact/me.dm7.barcodescanner/zxing
And here You can see the latest version is 1.9.8.
Upvotes: 5
Reputation: 59
As others have said, you just need to add this to your build.gradle
file:
repositories {
google()
mavenCentral()
}
And after that you need to change the version of the dependency to 'me.dm7.barcodescanner:zxing:1.9.8'
.
Finally you can delete jcenter()
since it's deprecated.
Upvotes: 5
Reputation: 6160
JCenter is deprecated and in read-only mode, therefore you might not find the library you're looking for.
Just use the following code in the build.gradle
file, sync the project and you're good to go.
repositories {
google()
mavenCentral()
}
Upvotes: 0