Compartir a través de


SystemSettings.ScreenOrientation (Propiedad)

Actualización: noviembre 2007

Obtiene o establece la orientación de la pantalla actual de un dispositivo.

Espacio de nombres:  Microsoft.WindowsCE.Forms
Ensamblado:  Microsoft.WindowsCE.Forms (en Microsoft.WindowsCE.Forms.dll)

Sintaxis

'Declaración
Public Shared Property ScreenOrientation As ScreenOrientation
'Uso
Dim value As ScreenOrientation

value = SystemSettings.ScreenOrientation

SystemSettings.ScreenOrientation = value
public static ScreenOrientation ScreenOrientation { get; set; }
public:
static property ScreenOrientation ScreenOrientation {
    ScreenOrientation get ();
    void set (ScreenOrientation value);
}
public static function get ScreenOrientation () : ScreenOrientation
public static function set ScreenOrientation (value : ScreenOrientation)

Valor de propiedad

Tipo: Microsoft.WindowsCE.Forms.ScreenOrientation
Uno de los valores de enumeración, que son 0, 90, 180 y 270. El valor predeterminado es 0 (vista vertical).

Comentarios

Se puede cambiar el valor de orientación vertical (0) a 90, 180 o 270 sin restablecer el dispositivo.

Ejemplos

En el ejemplo de código siguiente se establece el valor de esta propiedad en 0 y se muestra el valor en la barra de estado. Este ejemplo forma parte de un ejemplo más extenso referente a la clase SystemSettings.

' Set the screen orientation to normal
' and display the value on the status bar.
SystemSettings.ScreenOrientation = ScreenOrientation.Angle0
Me.StatusBar1.Text = SystemSettings.ScreenOrientation.ToString()
// Set the screen orientation to normal
// and display the value on the status bar.
SystemSettings.ScreenOrientation = ScreenOrientation.Angle0;
this.statusBar1.Text = SystemSettings.ScreenOrientation.ToString();

Permisos

Plataformas

Windows CE, Windows Mobile para Smartphone, Windows Mobile para Pocket PC

.NET Framework y .NET Compact Framework no admiten todas las versiones de cada plataforma. Para obtener una lista de las versiones compatibles, vea Requisitos de sistema de .NET Framework.

Información de versión

.NET Compact Framework

Compatible con: 3.5, 2.0

Vea también

Referencia

SystemSettings (Clase)

SystemSettings (Miembros)

Microsoft.WindowsCE.Forms (Espacio de nombres)