ANDROID screen orientation change?

The crash occurred at line 80 of MainActivity.

At com.loginpage.MainActivity. StorePreferences(MainActivity. Java:80) The crash occurred at line 80 of MainActivity.To avoid recreation of your activity add this to your manifest file android:configChanges="keyboarddden|orientation" and this to the activity @Override public void onConfigurationChanged(Configuration newConfig) { super.

OnConfigurationChanged(newConfig); setContentView(R.layout. MyLayout); }.

I have an EditText View in my layout, I used the setContentView(R.layout. MyLayout) but when the screen orientation changes the characters that I typed inside the EditText are erased.. – cindy May 12 at 8:06 sorry for my naive questions.. I am totally new to android... I really appreciate your help.. :) – cindy May 12 at 8:08 Use this – Reno May 12 at 8:14.

You should post the code, anyway, the stack trace tells you a lot: Java null pointer exception at MainActivity. StorePreferences(MainActivity. Java:80) Debug/check your code..

Put this android:screenOrientation="sensor" android:configChanges="keyboarddden|orientation" on the declaration of the activity in the AndroidManifest. Xml like this.

I cant really gove you an answer,but what I can give you is a way to a solution, that is you have to find the anglde that you relate to or peaks your interest. A good paper is one that people get drawn into because it reaches them ln some way.As for me WW11 to me, I think of the holocaust and the effect it had on the survivors, their families and those who stood by and did nothing until it was too late.

Related Questions