Compartir a través de


Shape.AccessibleName (Propiedad)

Obtiene o establece el nombre del control utilizado por aplicaciones cliente de accesibilidad.

Espacio de nombres:  Microsoft.VisualBasic.PowerPacks
Ensamblado:  Microsoft.VisualBasic.PowerPacks.Vs (en Microsoft.VisualBasic.PowerPacks.Vs.dll)

Sintaxis

'Declaración
<BrowsableAttribute(True)> _
Public Property AccessibleName As String
[BrowsableAttribute(true)]
public string AccessibleName { get; set; }
[BrowsableAttribute(true)]
public:
property String^ AccessibleName {
    String^ get ();
    void set (String^ value);
}
[<BrowsableAttribute(true)>]
member AccessibleName : string with get, set
function get AccessibleName () : String
function set AccessibleName (value : String)

Valor de propiedad

Tipo: System.String
String que representa el nombre del control utilizado por aplicaciones cliente de accesibilidad.El valor predeterminado es una referencia nula (Nothing en Visual Basic).

Comentarios

La propiedad de AccessibleName es una etiqueta que describe e identifica brevemente el objeto dentro de su contenedor.Por ejemplo, una forma podría tener AccessibleName “cuadrado pequeño oval” o “blue”. Una línea podría tener AccessibleName de “línea vertical” o “línea roja diagonal”.

Ejemplos

El ejemplo siguiente se muestra cómo establecer las propiedades de AccessibleName y de AccessibleDescription para un control de OvalShape .Suponga que se ha agregado un archivo de imagen denominado “cactus” como recursos en el proyecto.

Dim OvalShape1 As New OvalShape
Dim canvas As New ShapeContainer
' Set the form as the parent of the ShapeContainer.
canvas.Parent = Me
' Set the ShapeContainer as the parent of the OvalShape.
OvalShape1.Parent = canvas
' Assign an image resource to the BackgroundImage property.
OvalShape1.BackgroundImage = My.Resources.cactus
OvalShape1.Size = New Size(My.Resources.cactus.Size)
' Assign the AccessibleName and AccessibleDescription text.
OvalShape1.AccessibleName = "Image"
OvalShape1.AccessibleDescription = "A picture of a cactus"
OvalShape OvalShape1 = new OvalShape();
ShapeContainer canvas = new ShapeContainer();
// Set the form as the parent of the ShapeContainer.
canvas.Parent = this;
// Set the ShapeContainer as the parent of the OvalShape.
OvalShape1.Parent = canvas;
// Assign an image resource to the BackgroundImage property.
OvalShape1.BackgroundImage = VbPowerPacksShapeAccessibleCS.Properties.Resources.cactus;
OvalShape1.Size = new Size(VbPowerPacksShapeAccessibleCS.Properties.Resources.cactus.Height, 
    VbPowerPacksShapeAccessibleCS.Properties.Resources.cactus.Width);
// Assign the AccessibleName and AccessibleDescription text.
OvalShape1.AccessibleName = "Image";
OvalShape1.AccessibleDescription = "A picture of a cactus";

Seguridad de .NET Framework

Vea también

Referencia

Shape Clase

Microsoft.VisualBasic.PowerPacks (Espacio de nombres)

Otros recursos

Cómo: Dibujar líneas con el control LineShape (Visual Studio)

Cómo: Dibujar formas con los controles OvalShape y RectangleShape (Visual Studio)

Introducción a los controles de líneas y formas (Visual Studio)