Android Studioにてレーダーチャートを表示させるためにMPAndroidChartを用いたいです。
そこでいくつかサイトを見たところ、build.gradle(Module:app)に
repositories { maven { url "https://jitpack.io" } } dependencies { compile 'com.github.PhilJay:MPAndroidChart:v2.1.0' }
と追加するということが書かれており、その通りにしてみたのですが
Failed to resolve: com.github.PhilJay:MPAndroidChart:v2.1.0 Show in File Show in Project Structure dialog
というエラーが出てしまいます。
当方Gradleというものを今まで全く知らなかった初心者ですがよろしくお願い致します。
###追記
https://jitpack.io/#PhilJay/MPAndroidChart/v3.0.0
https://github.com/PhilJay/MPAndroidChart/blob/master/MPChartExample/build.gradle
こちらを参考にし、修正したgradle.build(Module:app)の全文です。
apply plugin: 'com.android.application' android { compileSdkVersion 24 buildToolsVersion "24.0.3" defaultConfig { applicationId "com.example.murasakiame.test" minSdkVersion 15 targetSdkVersion 24 versionCode 1 versionName "1.0" testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner" } buildTypes { release { minifyEnabled false proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro' } } } dependencies { compile fileTree(dir: 'libs', include: ['*.jar']) androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', { exclude group: 'com.android.support', module: 'support-annotations' }) compile 'com.android.support:appcompat-v7:24.2.1' testCompile 'junit:junit:4.12' compile 'com.android.support:cardview-v7:24.2.1' compile 'com.android.support:design:24.2.1' } //下記修正部分 allprojects{ repositories { maven { url "https://jitpack.io" } maven { url 'http://oss.jfrog.org/artifactory/oss-snapshot-local' } } } dependencies { compile 'com.github.PhilJay:MPAndroidChart:v3.0.0@aar' compile project(':MPChartLib') compile 'com.android.support:appcompat-v7:24.2.1' }
このようにしたところ、今度は下記のようなエラーが出てしまいました。
Project with path ':MPChartLib' could not be found in project ':app'.
修正部もあまりよく分かってなく貼り付けただけなので、何かおかしなところがあればご指摘ください。
回答1件
あなたの回答
tips
プレビュー
バッドをするには、ログインかつ
こちらの条件を満たす必要があります。
2016/11/10 15:07
2016/11/10 17:44
2016/11/16 12:05
2016/11/16 12:33
2016/11/18 11:56