How can I block the horizontal orientation in xamarin IOS. Only that it can be seen vertically.
How can I block the horizontal orientation in xamarin IOS. Only that it can be seen vertically.
You can see in the documentation how to do it for iOS with Xamarin, you have to define the property of orientation to your Activity,
either Landscape (horizontal):
ScreenOrientation.Landscape
o Portrait (vertical):
ScreenOrientation.Portrait
Example:
[Activity (Label = "MyRotatingApp.Droid", Icon = "@drawable/icon", MainLauncher = true, ConfigurationChanges = ConfigChanges.ScreenSize | ConfigChanges.Orientation,
ScreenOrientation = ScreenOrientation.Landscape)] //Esto es lo que controla la orientacion.
This is the documentation: