Android X: tools:replace specified at line: for attribute, but no new value specified











up vote
2
down vote

favorite












I have tried many solutions on this website but still, the problem is not solved. The issue is due to Android X library. When I added Android X, this issue was resolved but it opened up new issue. I don't want to add Android X. How to fix this issue?



Earlier this error was coming:



Manifest merger failed : Attribute application@appComponentFactory value=(android.support.v4.app.CoreComponentFactory) from [com.android.support:support-compat:28.0.0] AndroidManifest.xml:22:18-91
is also present at [androidx.core:core:1.0.0] AndroidManifest.xml:22:18-86 value=(androidx.core.app.CoreComponentFactory).
Suggestion: add 'tools:replace="android:appComponentFactory"' to <application> element at AndroidManifest.xml:19:5-142:19 to override.


After I added tools:replace="android:appComponentFactory", this error is came:



 java.lang.RuntimeException: Manifest merger failed with multiple errors, see logs
at com.android.builder.core.AndroidBuilder.mergeManifestsForApplication(AndroidBuilder.java:540)
at com.android.build.gradle.tasks.MergeManifests.doFullTaskAction(MergeManifests.java:173)


Merging Error (in Android Manifest):




Error: tools:replace specified at line:2 for attribute
android:appComponentFactory, but no new value specified app main
manifest (this file), line 1




Manifest:



<?xml version="1.0" encoding="utf-8"?>
<manifest
package="com.example"
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
tools:replace="allowBackup, android:appComponentFactory"
android:allowBackup="false">

...

<application
android:name="com.example"
android:icon="@mipmap/icon"
android:debuggable="true"
android:hardwareAccelerated="false"
android:largeHeap="true"
android:supportsRtl="true"
android:theme="@style/AppTheme"
android:allowBackup="false"
tools:ignore="GoogleAppIndexingWarning,HardcodedDebugMode">
...


dependencies block in module level build.gradle:



dependencies {
implementation fileTree(include: ['*.jar'], dir: 'libs')
implementation project(':autoupdatesdk-release')
//AppCompat v7 support library
//noinspection GradleCompatible
implementation 'com.android.support:appcompat-v7:28.0.0'
//AppCompat v4 support library
implementation 'com.android.support:support-v4:28.0.0'

//Support design
implementation 'com.android.support:design:28.0.0'
//Google Maps
implementation 'com.google.android.gms:play-services-maps:16.0.0'
//Retrofit - for making REST API calls
implementation 'com.squareup.retrofit2:converter-gson:2.3.0'
//For Runtime permissions
implementation 'com.karumi:dexter:5.0.0'
// https://mvnrepository.com/artifact/javax.annotation/javax.annotation-api
implementation group: 'javax.annotation', name: 'javax.annotation-api', version: '1.2'
//To set custom fonts
implementation 'uk.co.chrisjenx:calligraphy:2.2.0'
//Attaches bullets to viewpager
implementation 'com.robohorse.pagerbullet:pagerbullet:1.0.8'
//Expandable recycler view
implementation 'com.bignerdranch.android:expandablerecyclerview:3.0.0-RC1'
//For Graph
implementation 'com.github.PhilJay:MPAndroidChart:v3.0.3'
//Date time
implementation 'com.wdullaer:materialdatetimepicker:4.0.1'
implementation 'com.appeaser.sublimepickerlibrary:sublimepickerlibrary:2.1.2'

//Recycler View. Used in Select A Trip screen, Select A Site screen.
implementation 'com.android.support:recyclerview-v7:28.0.0'
implementation 'com.android.support:support-annotations:28.0.0'
testImplementation 'junit:junit:4.12'
androidTestImplementation 'com.android.support:support-annotations:28.0.0'
androidTestImplementation 'com.android.support.test:runner:1.0.2'
androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2'
implementation 'com.android.support:cardview-v7:28.0.0'
implementation 'jp.wasabeef:recyclerview-animators:2.2.6'
implementation 'org.greenrobot:greendao:3.2.2'

implementation 'net.danlew:android.joda:2.9.9.4'
implementation 'com.github.barteksc:android-pdf-viewer:3.0.0-beta.5'
implementation "org.jetbrains.kotlin:kotlin-stdlib:1.2.71"
implementation 'org.jetbrains.anko:anko-common:0.8.3'
implementation "io.reactivex.rxjava2:rxjava:2.1.12"
implementation 'io.reactivex:rxjava:1.2.0'
configurations.all {
exclude group: 'com.android.support', module: 'support-v13'
}
implementation 'com.squareup.retrofit2:converter-scalars:2.1.0'

implementation 'com.squareup:android-times-square:1.6.5@aar'
implementation 'io.reactivex.rxjava2:rxandroid:2.0.2'
configurations.all {
exclude group: 'com.android.support', module: 'support-v13'
}
implementation "com.daimajia.swipelayout:library:1.2.0@aar"
androidTestImplementation 'com.android.support.test.espresso:espresso-core:2.2.2', {
exclude group: 'com.android.support', module: 'support-annotations'
}
implementation 'com.elyeproj.libraries:loaderviewlibrary:1.4.1'
implementation 'com.squareup.picasso:picasso:2.71828'
implementation ('com.h6ah4i.android.widget.advrecyclerview:advrecyclerview:0.11.0@aar'){
transitive=true
}
testImplementation 'junit:junit:4.12'
testImplementation 'org.mockito:mockito-core:1.10.19'
implementation 'com.android.support.constraint:constraint-layout:1.1.3'

implementation('com.crashlytics.sdk.android:crashlytics:2.9.2@aar') {
transitive = true
}









share|improve this question




























    up vote
    2
    down vote

    favorite












    I have tried many solutions on this website but still, the problem is not solved. The issue is due to Android X library. When I added Android X, this issue was resolved but it opened up new issue. I don't want to add Android X. How to fix this issue?



    Earlier this error was coming:



    Manifest merger failed : Attribute application@appComponentFactory value=(android.support.v4.app.CoreComponentFactory) from [com.android.support:support-compat:28.0.0] AndroidManifest.xml:22:18-91
    is also present at [androidx.core:core:1.0.0] AndroidManifest.xml:22:18-86 value=(androidx.core.app.CoreComponentFactory).
    Suggestion: add 'tools:replace="android:appComponentFactory"' to <application> element at AndroidManifest.xml:19:5-142:19 to override.


    After I added tools:replace="android:appComponentFactory", this error is came:



     java.lang.RuntimeException: Manifest merger failed with multiple errors, see logs
    at com.android.builder.core.AndroidBuilder.mergeManifestsForApplication(AndroidBuilder.java:540)
    at com.android.build.gradle.tasks.MergeManifests.doFullTaskAction(MergeManifests.java:173)


    Merging Error (in Android Manifest):




    Error: tools:replace specified at line:2 for attribute
    android:appComponentFactory, but no new value specified app main
    manifest (this file), line 1




    Manifest:



    <?xml version="1.0" encoding="utf-8"?>
    <manifest
    package="com.example"
    xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:tools="http://schemas.android.com/tools"
    tools:replace="allowBackup, android:appComponentFactory"
    android:allowBackup="false">

    ...

    <application
    android:name="com.example"
    android:icon="@mipmap/icon"
    android:debuggable="true"
    android:hardwareAccelerated="false"
    android:largeHeap="true"
    android:supportsRtl="true"
    android:theme="@style/AppTheme"
    android:allowBackup="false"
    tools:ignore="GoogleAppIndexingWarning,HardcodedDebugMode">
    ...


    dependencies block in module level build.gradle:



    dependencies {
    implementation fileTree(include: ['*.jar'], dir: 'libs')
    implementation project(':autoupdatesdk-release')
    //AppCompat v7 support library
    //noinspection GradleCompatible
    implementation 'com.android.support:appcompat-v7:28.0.0'
    //AppCompat v4 support library
    implementation 'com.android.support:support-v4:28.0.0'

    //Support design
    implementation 'com.android.support:design:28.0.0'
    //Google Maps
    implementation 'com.google.android.gms:play-services-maps:16.0.0'
    //Retrofit - for making REST API calls
    implementation 'com.squareup.retrofit2:converter-gson:2.3.0'
    //For Runtime permissions
    implementation 'com.karumi:dexter:5.0.0'
    // https://mvnrepository.com/artifact/javax.annotation/javax.annotation-api
    implementation group: 'javax.annotation', name: 'javax.annotation-api', version: '1.2'
    //To set custom fonts
    implementation 'uk.co.chrisjenx:calligraphy:2.2.0'
    //Attaches bullets to viewpager
    implementation 'com.robohorse.pagerbullet:pagerbullet:1.0.8'
    //Expandable recycler view
    implementation 'com.bignerdranch.android:expandablerecyclerview:3.0.0-RC1'
    //For Graph
    implementation 'com.github.PhilJay:MPAndroidChart:v3.0.3'
    //Date time
    implementation 'com.wdullaer:materialdatetimepicker:4.0.1'
    implementation 'com.appeaser.sublimepickerlibrary:sublimepickerlibrary:2.1.2'

    //Recycler View. Used in Select A Trip screen, Select A Site screen.
    implementation 'com.android.support:recyclerview-v7:28.0.0'
    implementation 'com.android.support:support-annotations:28.0.0'
    testImplementation 'junit:junit:4.12'
    androidTestImplementation 'com.android.support:support-annotations:28.0.0'
    androidTestImplementation 'com.android.support.test:runner:1.0.2'
    androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2'
    implementation 'com.android.support:cardview-v7:28.0.0'
    implementation 'jp.wasabeef:recyclerview-animators:2.2.6'
    implementation 'org.greenrobot:greendao:3.2.2'

    implementation 'net.danlew:android.joda:2.9.9.4'
    implementation 'com.github.barteksc:android-pdf-viewer:3.0.0-beta.5'
    implementation "org.jetbrains.kotlin:kotlin-stdlib:1.2.71"
    implementation 'org.jetbrains.anko:anko-common:0.8.3'
    implementation "io.reactivex.rxjava2:rxjava:2.1.12"
    implementation 'io.reactivex:rxjava:1.2.0'
    configurations.all {
    exclude group: 'com.android.support', module: 'support-v13'
    }
    implementation 'com.squareup.retrofit2:converter-scalars:2.1.0'

    implementation 'com.squareup:android-times-square:1.6.5@aar'
    implementation 'io.reactivex.rxjava2:rxandroid:2.0.2'
    configurations.all {
    exclude group: 'com.android.support', module: 'support-v13'
    }
    implementation "com.daimajia.swipelayout:library:1.2.0@aar"
    androidTestImplementation 'com.android.support.test.espresso:espresso-core:2.2.2', {
    exclude group: 'com.android.support', module: 'support-annotations'
    }
    implementation 'com.elyeproj.libraries:loaderviewlibrary:1.4.1'
    implementation 'com.squareup.picasso:picasso:2.71828'
    implementation ('com.h6ah4i.android.widget.advrecyclerview:advrecyclerview:0.11.0@aar'){
    transitive=true
    }
    testImplementation 'junit:junit:4.12'
    testImplementation 'org.mockito:mockito-core:1.10.19'
    implementation 'com.android.support.constraint:constraint-layout:1.1.3'

    implementation('com.crashlytics.sdk.android:crashlytics:2.9.2@aar') {
    transitive = true
    }









    share|improve this question


























      up vote
      2
      down vote

      favorite









      up vote
      2
      down vote

      favorite











      I have tried many solutions on this website but still, the problem is not solved. The issue is due to Android X library. When I added Android X, this issue was resolved but it opened up new issue. I don't want to add Android X. How to fix this issue?



      Earlier this error was coming:



      Manifest merger failed : Attribute application@appComponentFactory value=(android.support.v4.app.CoreComponentFactory) from [com.android.support:support-compat:28.0.0] AndroidManifest.xml:22:18-91
      is also present at [androidx.core:core:1.0.0] AndroidManifest.xml:22:18-86 value=(androidx.core.app.CoreComponentFactory).
      Suggestion: add 'tools:replace="android:appComponentFactory"' to <application> element at AndroidManifest.xml:19:5-142:19 to override.


      After I added tools:replace="android:appComponentFactory", this error is came:



       java.lang.RuntimeException: Manifest merger failed with multiple errors, see logs
      at com.android.builder.core.AndroidBuilder.mergeManifestsForApplication(AndroidBuilder.java:540)
      at com.android.build.gradle.tasks.MergeManifests.doFullTaskAction(MergeManifests.java:173)


      Merging Error (in Android Manifest):




      Error: tools:replace specified at line:2 for attribute
      android:appComponentFactory, but no new value specified app main
      manifest (this file), line 1




      Manifest:



      <?xml version="1.0" encoding="utf-8"?>
      <manifest
      package="com.example"
      xmlns:android="http://schemas.android.com/apk/res/android"
      xmlns:tools="http://schemas.android.com/tools"
      tools:replace="allowBackup, android:appComponentFactory"
      android:allowBackup="false">

      ...

      <application
      android:name="com.example"
      android:icon="@mipmap/icon"
      android:debuggable="true"
      android:hardwareAccelerated="false"
      android:largeHeap="true"
      android:supportsRtl="true"
      android:theme="@style/AppTheme"
      android:allowBackup="false"
      tools:ignore="GoogleAppIndexingWarning,HardcodedDebugMode">
      ...


      dependencies block in module level build.gradle:



      dependencies {
      implementation fileTree(include: ['*.jar'], dir: 'libs')
      implementation project(':autoupdatesdk-release')
      //AppCompat v7 support library
      //noinspection GradleCompatible
      implementation 'com.android.support:appcompat-v7:28.0.0'
      //AppCompat v4 support library
      implementation 'com.android.support:support-v4:28.0.0'

      //Support design
      implementation 'com.android.support:design:28.0.0'
      //Google Maps
      implementation 'com.google.android.gms:play-services-maps:16.0.0'
      //Retrofit - for making REST API calls
      implementation 'com.squareup.retrofit2:converter-gson:2.3.0'
      //For Runtime permissions
      implementation 'com.karumi:dexter:5.0.0'
      // https://mvnrepository.com/artifact/javax.annotation/javax.annotation-api
      implementation group: 'javax.annotation', name: 'javax.annotation-api', version: '1.2'
      //To set custom fonts
      implementation 'uk.co.chrisjenx:calligraphy:2.2.0'
      //Attaches bullets to viewpager
      implementation 'com.robohorse.pagerbullet:pagerbullet:1.0.8'
      //Expandable recycler view
      implementation 'com.bignerdranch.android:expandablerecyclerview:3.0.0-RC1'
      //For Graph
      implementation 'com.github.PhilJay:MPAndroidChart:v3.0.3'
      //Date time
      implementation 'com.wdullaer:materialdatetimepicker:4.0.1'
      implementation 'com.appeaser.sublimepickerlibrary:sublimepickerlibrary:2.1.2'

      //Recycler View. Used in Select A Trip screen, Select A Site screen.
      implementation 'com.android.support:recyclerview-v7:28.0.0'
      implementation 'com.android.support:support-annotations:28.0.0'
      testImplementation 'junit:junit:4.12'
      androidTestImplementation 'com.android.support:support-annotations:28.0.0'
      androidTestImplementation 'com.android.support.test:runner:1.0.2'
      androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2'
      implementation 'com.android.support:cardview-v7:28.0.0'
      implementation 'jp.wasabeef:recyclerview-animators:2.2.6'
      implementation 'org.greenrobot:greendao:3.2.2'

      implementation 'net.danlew:android.joda:2.9.9.4'
      implementation 'com.github.barteksc:android-pdf-viewer:3.0.0-beta.5'
      implementation "org.jetbrains.kotlin:kotlin-stdlib:1.2.71"
      implementation 'org.jetbrains.anko:anko-common:0.8.3'
      implementation "io.reactivex.rxjava2:rxjava:2.1.12"
      implementation 'io.reactivex:rxjava:1.2.0'
      configurations.all {
      exclude group: 'com.android.support', module: 'support-v13'
      }
      implementation 'com.squareup.retrofit2:converter-scalars:2.1.0'

      implementation 'com.squareup:android-times-square:1.6.5@aar'
      implementation 'io.reactivex.rxjava2:rxandroid:2.0.2'
      configurations.all {
      exclude group: 'com.android.support', module: 'support-v13'
      }
      implementation "com.daimajia.swipelayout:library:1.2.0@aar"
      androidTestImplementation 'com.android.support.test.espresso:espresso-core:2.2.2', {
      exclude group: 'com.android.support', module: 'support-annotations'
      }
      implementation 'com.elyeproj.libraries:loaderviewlibrary:1.4.1'
      implementation 'com.squareup.picasso:picasso:2.71828'
      implementation ('com.h6ah4i.android.widget.advrecyclerview:advrecyclerview:0.11.0@aar'){
      transitive=true
      }
      testImplementation 'junit:junit:4.12'
      testImplementation 'org.mockito:mockito-core:1.10.19'
      implementation 'com.android.support.constraint:constraint-layout:1.1.3'

      implementation('com.crashlytics.sdk.android:crashlytics:2.9.2@aar') {
      transitive = true
      }









      share|improve this question















      I have tried many solutions on this website but still, the problem is not solved. The issue is due to Android X library. When I added Android X, this issue was resolved but it opened up new issue. I don't want to add Android X. How to fix this issue?



      Earlier this error was coming:



      Manifest merger failed : Attribute application@appComponentFactory value=(android.support.v4.app.CoreComponentFactory) from [com.android.support:support-compat:28.0.0] AndroidManifest.xml:22:18-91
      is also present at [androidx.core:core:1.0.0] AndroidManifest.xml:22:18-86 value=(androidx.core.app.CoreComponentFactory).
      Suggestion: add 'tools:replace="android:appComponentFactory"' to <application> element at AndroidManifest.xml:19:5-142:19 to override.


      After I added tools:replace="android:appComponentFactory", this error is came:



       java.lang.RuntimeException: Manifest merger failed with multiple errors, see logs
      at com.android.builder.core.AndroidBuilder.mergeManifestsForApplication(AndroidBuilder.java:540)
      at com.android.build.gradle.tasks.MergeManifests.doFullTaskAction(MergeManifests.java:173)


      Merging Error (in Android Manifest):




      Error: tools:replace specified at line:2 for attribute
      android:appComponentFactory, but no new value specified app main
      manifest (this file), line 1




      Manifest:



      <?xml version="1.0" encoding="utf-8"?>
      <manifest
      package="com.example"
      xmlns:android="http://schemas.android.com/apk/res/android"
      xmlns:tools="http://schemas.android.com/tools"
      tools:replace="allowBackup, android:appComponentFactory"
      android:allowBackup="false">

      ...

      <application
      android:name="com.example"
      android:icon="@mipmap/icon"
      android:debuggable="true"
      android:hardwareAccelerated="false"
      android:largeHeap="true"
      android:supportsRtl="true"
      android:theme="@style/AppTheme"
      android:allowBackup="false"
      tools:ignore="GoogleAppIndexingWarning,HardcodedDebugMode">
      ...


      dependencies block in module level build.gradle:



      dependencies {
      implementation fileTree(include: ['*.jar'], dir: 'libs')
      implementation project(':autoupdatesdk-release')
      //AppCompat v7 support library
      //noinspection GradleCompatible
      implementation 'com.android.support:appcompat-v7:28.0.0'
      //AppCompat v4 support library
      implementation 'com.android.support:support-v4:28.0.0'

      //Support design
      implementation 'com.android.support:design:28.0.0'
      //Google Maps
      implementation 'com.google.android.gms:play-services-maps:16.0.0'
      //Retrofit - for making REST API calls
      implementation 'com.squareup.retrofit2:converter-gson:2.3.0'
      //For Runtime permissions
      implementation 'com.karumi:dexter:5.0.0'
      // https://mvnrepository.com/artifact/javax.annotation/javax.annotation-api
      implementation group: 'javax.annotation', name: 'javax.annotation-api', version: '1.2'
      //To set custom fonts
      implementation 'uk.co.chrisjenx:calligraphy:2.2.0'
      //Attaches bullets to viewpager
      implementation 'com.robohorse.pagerbullet:pagerbullet:1.0.8'
      //Expandable recycler view
      implementation 'com.bignerdranch.android:expandablerecyclerview:3.0.0-RC1'
      //For Graph
      implementation 'com.github.PhilJay:MPAndroidChart:v3.0.3'
      //Date time
      implementation 'com.wdullaer:materialdatetimepicker:4.0.1'
      implementation 'com.appeaser.sublimepickerlibrary:sublimepickerlibrary:2.1.2'

      //Recycler View. Used in Select A Trip screen, Select A Site screen.
      implementation 'com.android.support:recyclerview-v7:28.0.0'
      implementation 'com.android.support:support-annotations:28.0.0'
      testImplementation 'junit:junit:4.12'
      androidTestImplementation 'com.android.support:support-annotations:28.0.0'
      androidTestImplementation 'com.android.support.test:runner:1.0.2'
      androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2'
      implementation 'com.android.support:cardview-v7:28.0.0'
      implementation 'jp.wasabeef:recyclerview-animators:2.2.6'
      implementation 'org.greenrobot:greendao:3.2.2'

      implementation 'net.danlew:android.joda:2.9.9.4'
      implementation 'com.github.barteksc:android-pdf-viewer:3.0.0-beta.5'
      implementation "org.jetbrains.kotlin:kotlin-stdlib:1.2.71"
      implementation 'org.jetbrains.anko:anko-common:0.8.3'
      implementation "io.reactivex.rxjava2:rxjava:2.1.12"
      implementation 'io.reactivex:rxjava:1.2.0'
      configurations.all {
      exclude group: 'com.android.support', module: 'support-v13'
      }
      implementation 'com.squareup.retrofit2:converter-scalars:2.1.0'

      implementation 'com.squareup:android-times-square:1.6.5@aar'
      implementation 'io.reactivex.rxjava2:rxandroid:2.0.2'
      configurations.all {
      exclude group: 'com.android.support', module: 'support-v13'
      }
      implementation "com.daimajia.swipelayout:library:1.2.0@aar"
      androidTestImplementation 'com.android.support.test.espresso:espresso-core:2.2.2', {
      exclude group: 'com.android.support', module: 'support-annotations'
      }
      implementation 'com.elyeproj.libraries:loaderviewlibrary:1.4.1'
      implementation 'com.squareup.picasso:picasso:2.71828'
      implementation ('com.h6ah4i.android.widget.advrecyclerview:advrecyclerview:0.11.0@aar'){
      transitive=true
      }
      testImplementation 'junit:junit:4.12'
      testImplementation 'org.mockito:mockito-core:1.10.19'
      implementation 'com.android.support.constraint:constraint-layout:1.1.3'

      implementation('com.crashlytics.sdk.android:crashlytics:2.9.2@aar') {
      transitive = true
      }






      java android android-gradle android-manifest androidx






      share|improve this question















      share|improve this question













      share|improve this question




      share|improve this question








      edited Nov 12 at 23:52

























      asked Nov 12 at 19:29









      Malwinder Singh

      2,34053161




      2,34053161
























          2 Answers
          2






          active

          oldest

          votes

















          up vote
          0
          down vote













          I think you are migrating to AndroidX libs.



          Add below lines to gradle.properties file



          android.useAndroidX=true
          android.enableJetifier=true


          Remove tools:replace="android:appComponentFactory" from manifest.



          Replace android.support.v7.app.AppCompatActivity to androidx.appcompat.app.AppCompatActivity



          Migrating to AndroidX






          share|improve this answer




























            up vote
            0
            down vote













            You can try adding:



            android:appComponentFactory="android.support.v4.app.CoreComponentFactory"


            To the tag <application > in your manifest.






            share|improve this answer























              Your Answer






              StackExchange.ifUsing("editor", function () {
              StackExchange.using("externalEditor", function () {
              StackExchange.using("snippets", function () {
              StackExchange.snippets.init();
              });
              });
              }, "code-snippets");

              StackExchange.ready(function() {
              var channelOptions = {
              tags: "".split(" "),
              id: "1"
              };
              initTagRenderer("".split(" "), "".split(" "), channelOptions);

              StackExchange.using("externalEditor", function() {
              // Have to fire editor after snippets, if snippets enabled
              if (StackExchange.settings.snippets.snippetsEnabled) {
              StackExchange.using("snippets", function() {
              createEditor();
              });
              }
              else {
              createEditor();
              }
              });

              function createEditor() {
              StackExchange.prepareEditor({
              heartbeatType: 'answer',
              convertImagesToLinks: true,
              noModals: true,
              showLowRepImageUploadWarning: true,
              reputationToPostImages: 10,
              bindNavPrevention: true,
              postfix: "",
              imageUploader: {
              brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
              contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
              allowUrls: true
              },
              onDemand: true,
              discardSelector: ".discard-answer"
              ,immediatelyShowMarkdownHelp:true
              });


              }
              });














               

              draft saved


              draft discarded


















              StackExchange.ready(
              function () {
              StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53268865%2fandroid-x-toolsreplace-specified-at-line-for-attribute-but-no-new-value-spec%23new-answer', 'question_page');
              }
              );

              Post as a guest















              Required, but never shown

























              2 Answers
              2






              active

              oldest

              votes








              2 Answers
              2






              active

              oldest

              votes









              active

              oldest

              votes






              active

              oldest

              votes








              up vote
              0
              down vote













              I think you are migrating to AndroidX libs.



              Add below lines to gradle.properties file



              android.useAndroidX=true
              android.enableJetifier=true


              Remove tools:replace="android:appComponentFactory" from manifest.



              Replace android.support.v7.app.AppCompatActivity to androidx.appcompat.app.AppCompatActivity



              Migrating to AndroidX






              share|improve this answer

























                up vote
                0
                down vote













                I think you are migrating to AndroidX libs.



                Add below lines to gradle.properties file



                android.useAndroidX=true
                android.enableJetifier=true


                Remove tools:replace="android:appComponentFactory" from manifest.



                Replace android.support.v7.app.AppCompatActivity to androidx.appcompat.app.AppCompatActivity



                Migrating to AndroidX






                share|improve this answer























                  up vote
                  0
                  down vote










                  up vote
                  0
                  down vote









                  I think you are migrating to AndroidX libs.



                  Add below lines to gradle.properties file



                  android.useAndroidX=true
                  android.enableJetifier=true


                  Remove tools:replace="android:appComponentFactory" from manifest.



                  Replace android.support.v7.app.AppCompatActivity to androidx.appcompat.app.AppCompatActivity



                  Migrating to AndroidX






                  share|improve this answer












                  I think you are migrating to AndroidX libs.



                  Add below lines to gradle.properties file



                  android.useAndroidX=true
                  android.enableJetifier=true


                  Remove tools:replace="android:appComponentFactory" from manifest.



                  Replace android.support.v7.app.AppCompatActivity to androidx.appcompat.app.AppCompatActivity



                  Migrating to AndroidX







                  share|improve this answer












                  share|improve this answer



                  share|improve this answer










                  answered Nov 13 at 8:48









                  Akshay

                  467313




                  467313
























                      up vote
                      0
                      down vote













                      You can try adding:



                      android:appComponentFactory="android.support.v4.app.CoreComponentFactory"


                      To the tag <application > in your manifest.






                      share|improve this answer



























                        up vote
                        0
                        down vote













                        You can try adding:



                        android:appComponentFactory="android.support.v4.app.CoreComponentFactory"


                        To the tag <application > in your manifest.






                        share|improve this answer

























                          up vote
                          0
                          down vote










                          up vote
                          0
                          down vote









                          You can try adding:



                          android:appComponentFactory="android.support.v4.app.CoreComponentFactory"


                          To the tag <application > in your manifest.






                          share|improve this answer














                          You can try adding:



                          android:appComponentFactory="android.support.v4.app.CoreComponentFactory"


                          To the tag <application > in your manifest.







                          share|improve this answer














                          share|improve this answer



                          share|improve this answer








                          edited Nov 13 at 21:53

























                          answered Nov 13 at 16:26









                          Gabriel Aguirre

                          1614




                          1614






























                               

                              draft saved


                              draft discarded



















































                               


                              draft saved


                              draft discarded














                              StackExchange.ready(
                              function () {
                              StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53268865%2fandroid-x-toolsreplace-specified-at-line-for-attribute-but-no-new-value-spec%23new-answer', 'question_page');
                              }
                              );

                              Post as a guest















                              Required, but never shown





















































                              Required, but never shown














                              Required, but never shown












                              Required, but never shown







                              Required, but never shown

































                              Required, but never shown














                              Required, but never shown












                              Required, but never shown







                              Required, but never shown







                              Popular posts from this blog

                              How to send String Array data to Server using php in android

                              Title Spacing in Bjornstrup Chapter, Removing Chapter Number From Contents

                              Is anime1.com a legal site for watching anime?