この質問はここで何度も尋ねられましたが、お勧めの解決策はありません。Android Studio 2.2.3シンボル 'R'を解決できません
私のIDEは、R.id属性とR.layoutでエラーを出します。私がファイルを変更しなくても、すべてのJavaファイルは突然同じエラーを出します。 私はすでに試してみました:
File->Invalidata Caches/Restart Invalidata and Restart
Build->Make Module
Build->Make Project
Build->Clean Project
Build->Rebuild Project
これは、アプリモジュールのための私のbuild.gradeファイルです:
apply plugin: 'com.android.application'
android {
compileSdkVersion 24
buildToolsVersion "25.0.1"
defaultConfig {
applicationId "com.example.sabrine.sos_remorquage"
minSdkVersion 17
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'
compile 'com.google.firebase:firebase-core:9.0.1'
compile 'com.google.firebase:firebase-auth:9.0.1'
compile 'com.google.firebase:firebase-database:9.0.1'
compile 'com.google.android.gms:play-services:9.0.1'
testCompile 'junit:junit:4.12'}
apply plugin: 'com.google.gms.google-services'
コンソールにエラーがありますか?それを投稿できますか? – Raghavendra
適切なインポートステートメントがありますか? – Raghavendra
R-はリソースを意味します。リソースファイルを完全にチェックする必要があります。アプリでエラーが発生しているためです。それはエラーによって単一のドットになる可能性があります。スタイル、文字列、生の、attr、色、レイアウト、描画可能、アニメーション、メニュー、カスタムXMLレイアウトファイルまたはフォルダ – Noorul