title: Unresolved reference: databinding in Android studio 4.1.3
body: <p>I face a wired behavior after following a lot of answers here in SO and other answers to solve but still stuck in it.</p>
  <p>I added to app Gradle</p>
  <pre><code>  buildFeatures {
      dataBinding true
  }
  </code></pre>
  <p>and my activity_main.xml is wrapped by layout</p>
  <pre><code>&lt;?xml version=&quot;1.0&quot; encoding=&quot;utf-8&quot;?&gt; 
  &lt;layout xmlns:android=&quot;http://schemas.android.com/apk/res/android&quot;&gt;
   &lt;data&gt; &lt;/data&gt;
  
  &lt;fragment xmlns:android=&quot;http://schemas.android.com/apk/res/android&quot;
      xmlns:tools=&quot;http://schemas.android.com/tools&quot;
      android:id=&quot;@+id/map&quot;
      android:name=&quot;com.google.android.gms.maps.SupportMapFragment&quot;
      android:layout_width=&quot;match_parent&quot;
      android:layout_height=&quot;match_parent&quot;
      tools:context=&quot;.ui.home.MainActivity&quot; /&gt;
    &lt;/layout&gt;
  </code></pre>
  <p>and I tried as well to add these to gradle.properties</p>
  <pre><code>android.databinding.enableV2=true
  android.useAndroidX=true
  </code></pre>
  <p>and I already have</p>
  <pre><code>android.useAndroidX=true
  android.enableJetifier=true
  </code></pre>
  <p><a href="https://i.stack.imgur.com/HlPB6.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/HlPB6.png" alt="Main Activity" /></a>
  it shows no error when open the activity and as well when changing the name to another it also appears to be generated but whenever I run I got this error</p>
  <pre><code>Unresolved reference: databinding
  </code></pre>
  <p><a href="https://i.stack.imgur.com/uwZlo.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/uwZlo.png" alt="enter image description here" /></a></p>
  <p>How I can solve this?</p>
  <p>**update 1
  I already did clean and build multiple times, closed the android studio and opened it, as well did Invalidate Cache/Restart.</p>