Compartir vía


ITextProvider.RangeFromChild(IRawElementProviderSimple) Método

Definición

Recupera un rango de texto que incluye un elemento secundario, como una imagen, un hipervínculo u otro objeto insertado.

public:
 System::Windows::Automation::Provider::ITextRangeProvider ^ RangeFromChild(System::Windows::Automation::Provider::IRawElementProviderSimple ^ childElement);
public System.Windows.Automation.Provider.ITextRangeProvider RangeFromChild (System.Windows.Automation.Provider.IRawElementProviderSimple childElement);
abstract member RangeFromChild : System.Windows.Automation.Provider.IRawElementProviderSimple -> System.Windows.Automation.Provider.ITextRangeProvider
Public Function RangeFromChild (childElement As IRawElementProviderSimple) As ITextRangeProvider

Parámetros

childElement
IRawElementProviderSimple

Objeto incluido.

Devoluciones

ITextRangeProvider

Un intervalo que abarca el elemento secundario.

Excepciones

Si el elemento secundario es una referencia nula (Nothing en Visual Basic).

Comentarios

Un proveedor de Automatización de la interfaz de usuario debe comprobar que el elemento pasado es un elemento secundario del contenedor de texto.

Si no hay texto en el intervalo donde existe el elemento secundario, se devuelve un intervalo degenerado (vacío).

El childElement parámetro es un elemento secundario del AutomationElement asociado a o TextPattern de la matriz de elementos secundarios de .TextPatternRange

Se aplica a

Consulte también