Click to Rate and Give Feedback
MSDN
MSDN Library
.NET Development
.NET Framework 3.5
 FindAttribute Method

  Switch on low bandwidth view
This page is specific to
Microsoft Visual Studio 2008/.NET Framework 3.5

Other versions are also available for the following:
.NET Framework Class Library
ITextRangeProvider..::.FindAttribute Method

Returns a text range subset that has the specified attribute value.

Namespace:  System.Windows.Automation.Provider
Assembly:  UIAutomationProvider (in UIAutomationProvider.dll)
Visual Basic (Declaration)
Function FindAttribute ( _
    attribute As Integer, _
    value As Object, _
    backward As Boolean _
) As ITextRangeProvider
Visual Basic (Usage)
Dim instance As ITextRangeProvider
Dim attribute As Integer
Dim value As Object
Dim backward As Boolean
Dim returnValue As ITextRangeProvider

returnValue = instance.FindAttribute(attribute, _
    value, backward)
C#
ITextRangeProvider FindAttribute(
    int attribute,
    Object value,
    bool backward
)
Visual C++
ITextRangeProvider^ FindAttribute(
    int attribute, 
    Object^ value, 
    bool backward
)
JScript
function FindAttribute(
    attribute : int, 
    value : Object, 
    backward : boolean
) : ITextRangeProvider

Parameters

attribute
Type: System..::.Int32
The attribute to search for.
value
Type: System..::.Object
The attribute value to search for. This value must match the type specified for the attribute.
backward
Type: System..::.Boolean
true if the last occurring text range should be returned instead of the first; otherwise false.

Return Value

Type: System.Windows.Automation.Provider..::.ITextRangeProvider
A text range having a matching attribute and attribute value; otherwise null (Nothing in Microsoft Visual Basic .NET).

There is no differentiation between hidden and visible text.

Windows 7, Windows Vista, Windows XP SP2, Windows Server 2008 R2, Windows Server 2008, Windows Server 2003

The .NET Framework and .NET Compact Framework do not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.

.NET Framework

Supported in: 3.5, 3.0
Tags What's this?: Add a tag
Community Content   What is Community Content?
Add new content RSS  Annotations
Processing
© 2009 Microsoft Corporation. All rights reserved. Terms of Use  |  Trademarks  |  Privacy Statement
Page view tracker