I am developing an Android app whose orientation I don\'t want changed to landscape mode when the user rotates the device. Also, I want the locked orientation to be portrait
You have to add the android:screenOrientation="portrait" directive in your AndroidManifest.xml
. This is to be done in your
In addition, the Android Developers guide states that :
[...] you should also explicitly declare that your application requires either portrait or landscape orientation with the element. For example,
.