what you can do is you can set the orientation in only one form so by this your activity is not recreated or you can add this line in your manifest that will handle orientation change
<activity name= ".YourActivity" android:configChanges="orientation|screenSize"/>
or you can save the state of you application in restore it when orientation is changed
protected void onSaveInstanceState(Bundle bundle) {
super.onSaveInstanceState(bundle);
bundle.putInt("param", valueInt); // you can save values that you want to
//retain when you orientation change is done
}
and onCreate method you can get them and assign them torelevent views
public void onCreate(Bundle bundle) {
if (bundle != null){
valueInt = bundle.getLong("param");
}
}