title: Landscape Screen Orientated not working in Android Studios
body: <p>I have created Android layout resource files for landscape mode for all different screen sizes such as, small, large, medium and extra large , however, when I run the app it does not work in landscape mode as half of the buttons, images are missing from the screen.</p>
  
  <p>I have also included the below line in the android Manifest file.</p>
  
  <pre><code>android:configChanges="orientation|screenSize|keyboardHidden"
  </code></pre>
  
  <p>I have included the below in all of the actvity java file and still not working.</p>
  
  <pre><code> public void onConfigurationChanged(Configuration newConfig) {
          super.onConfigurationChanged(newConfig);
  
          if(newConfig.orientation == Configuration.ORIENTATION_PORTRAIT) {
              Toast.makeText(getApplicationContext(), "Portrait Mode", Toast.LENGTH_SHORT).show();
          }else if(newConfig.orientation==Configuration.ORIENTATION_LANDSCAPE) {
              Toast.makeText(getApplicationContext(), "Landscape Mode", Toast.LENGTH_SHORT).show();
          }
  </code></pre>
  
  <p>Android does switch it to landscape mode, however, the elements within the screen are displayed incorrectly. I have created a landscape layout resource file, however, the problem is that Android does not use this layout as it uses the same layout in portrait and landscape mode. </p>
  
  <p>Please advice how I can make Android aware of when to use the landscape and portrait mode.</p>