UiPath Documentation
activities
latest
false
用户界面自动化活动
重要 :
请注意,此内容已使用机器翻译进行了部分本地化。 新发布内容的本地化可能需要 1-2 周的时间才能完成。

IsEnabled

检查是否启用了用户界面元素。

必须在“打开”“附加”之后添加此 API。

定义

命名空间:UiPath.UIAutomationNext.API.Models

程序集:UiPath.UIAutomationNext.API.Models(位于 UiPath.UIAutomationNext.API.Models dll 中)

重载

重载描述
IsEnabled(String)检查是否启用了由对象存储库中的字符串标识的用户界面元素。
IsEnabled(IElementDescriptor)检查是否启用了由对象存储库中元素描述符标识的用户界面元素。
IsEnabled(IElementDescriptor, IsEnabledOptions)检查是否启用了用户界面元素,该元素由对象存储库中元素的描述符以及其他选项标识。
IsEnabled(String, IsEnabledOptions)检查用户界面元素是否已启用,由对象存储库中的字符串以及其他选项标识。
IsEnabled(TargetAnchorableModel, IsEnabledOptions)检查用户界面元素是否已启用,由TargetAnchorableModel对象以及其他选项标识。
IsEnabled(RuntimeTarget, IsEnabledOptions)检查是否启用了由对象存储库元素的运行时实例及其他选项标识的用户界面元素。

IsEnabled(String)

检查是否启用了由对象存储库中的字符串标识的用户界面元素。

IsEnabled(
    string target)
IsEnabled(
    string target)

target String :要检查是否已启用的用户界面元素,由对象存储库中的字符串标识。

IsEnabled(IElementDescriptor)

检查是否启用了由对象存储库中元素描述符标识的用户界面元素。

IsEnabled(
    IElementDescriptor elementDescriptor)
IsEnabled(
    IElementDescriptor elementDescriptor)

elementDescriptor IElementDescriptor :要检查是否已启用的用户界面元素,由对象存储库中元素的描述符标识。

IsEnabled(IElementDescriptor, IsEnabledOptions)

检查是否启用了用户界面元素,该元素由对象存储库中元素的描述符以及其他选项标识。

IsEnabled(
    IElementDescriptor elementDescriptor,
    IsEnabledOptions isEnabledOptions)
IsEnabled(
    IElementDescriptor elementDescriptor,
    IsEnabledOptions isEnabledOptions)

elementDescriptor IElementDescriptor :要检查是否已启用的用户界面元素,由对象存储库中元素的描述符标识。

isEnabledOptions IsEnabledOptions :用于自定义验证流程的其他选项。您可以选择自定义以下项目:

* `TargetOptions`:
  + `Timeout` - Specifies the amount of time (in
    seconds) to wait for the API to run before the
    `SelectorNotFoundException` error is
    thrown. The default value is 30 seconds.
  + `DelayAfter` - Delay time (in seconds) after
    executing the API. The default amount of time is 0.3 seconds
    (300 milliseconds).
  + `DelayBefore` - Delay time (in seconds)
    before the API begins performing any operations. The default
    amount of time is 0.2 seconds (200 milliseconds).
* `TargetOptions`:
  + `Timeout` - Specifies the amount of time (in
    seconds) to wait for the API to run before the
    `SelectorNotFoundException` error is
    thrown. The default value is 30 seconds.
  + `DelayAfter` - Delay time (in seconds) after
    executing the API. The default amount of time is 0.3 seconds
    (300 milliseconds).
  + `DelayBefore` - Delay time (in seconds)
    before the API begins performing any operations. The default
    amount of time is 0.2 seconds (200 milliseconds).

IsEnabled(String, IsEnabledOptions)

检查用户界面元素是否已启用,由对象存储库中的字符串以及其他选项标识。

IsEnabled(
    string target,
    IsEnabledOptions isEnabledOptions)
IsEnabled(
    string target,
    IsEnabledOptions isEnabledOptions)

target String :要检查是否已启用的用户界面元素,由对象存储库中的字符串标识。

isEnabledOptions IsEnabledOptions :用于自定义验证流程的其他选项。您可以选择自定义以下项目:

* `TargetOptions`:
  + `Timeout` - Specifies the amount of time (in
    seconds) to wait for the API to run before the
    `SelectorNotFoundException` error is
    thrown. The default value is 30 seconds.
  + `DelayAfter` - Delay time (in seconds) after
    executing the API. The default amount of time is 0.3 seconds
    (300 milliseconds).
  + `DelayBefore` - Delay time (in seconds)
    before the API begins performing any operations. The default
    amount of time is 0.2 seconds (200 milliseconds).
* `TargetOptions`:
  + `Timeout` - Specifies the amount of time (in
    seconds) to wait for the API to run before the
    `SelectorNotFoundException` error is
    thrown. The default value is 30 seconds.
  + `DelayAfter` - Delay time (in seconds) after
    executing the API. The default amount of time is 0.3 seconds
    (300 milliseconds).
  + `DelayBefore` - Delay time (in seconds)
    before the API begins performing any operations. The default
    amount of time is 0.2 seconds (200 milliseconds).

IsEnabled(TargetAnchorableModel, IsEnabledOptions)

检查用户界面元素是否已启用,由TargetAnchorableModel对象以及其他选项标识。

IsEnabled(
    TargetAnchorableModel target,
    IsEnabledOptions isEnabledOptions)
IsEnabled(
    TargetAnchorableModel target,
    IsEnabledOptions isEnabledOptions)

target TargetAnchorableModel :要检查是否已启用的用户界面元素,由TargetAnchorableModel对象标识。

isEnabledOptions IsEnabledOptions :用于自定义验证流程的其他选项。您可以选择自定义以下项目:

* `TargetOptions`:
  + `Timeout` - Specifies the amount of time (in
    seconds) to wait for the API to run before the
    `SelectorNotFoundException` error is
    thrown. The default value is 30 seconds.
  + `DelayAfter` - Delay time (in seconds) after
    executing the API. The default amount of time is 0.3 seconds
    (300 milliseconds).
  + `DelayBefore` - Delay time (in seconds)
    before the API begins performing any operations. The default
    amount of time is 0.2 seconds (200 milliseconds).
* `TargetOptions`:
  + `Timeout` - Specifies the amount of time (in
    seconds) to wait for the API to run before the
    `SelectorNotFoundException` error is
    thrown. The default value is 30 seconds.
  + `DelayAfter` - Delay time (in seconds) after
    executing the API. The default amount of time is 0.3 seconds
    (300 milliseconds).
  + `DelayBefore` - Delay time (in seconds)
    before the API begins performing any operations. The default
    amount of time is 0.2 seconds (200 milliseconds).

IsEnabled(RuntimeTarget, IsEnabledOptions)

检查是否启用了由对象存储库元素的运行时实例及其他选项标识的用户界面元素。

IsEnabled(
    RuntimeTarget target,
    [IsEnabledOptions isEnabledOptions])
IsEnabled(
    RuntimeTarget target,
    [IsEnabledOptions isEnabledOptions])

target RuntimeTarget :要检查是否已启用的用户界面元素,由对象存储库元素的运行时实例标识。

isEnabledOptions IsEnabledOptions :用于自定义验证流程的其他选项。您可以选择自定义以下项目:

* `TargetOptions`:
  + `Timeout` - Specifies the amount of time (in
    seconds) to wait for the API to run before the
    `SelectorNotFoundException` error is
    thrown. The default value is 30 seconds.
  + `DelayAfter` - Delay time (in seconds) after
    executing the API. The default amount of time is 0.3 seconds
    (300 milliseconds).
  + `DelayBefore` - Delay time (in seconds)
    before the API begins performing any operations. The default
    amount of time is 0.2 seconds (200 milliseconds).
* `TargetOptions`:
  + `Timeout` - Specifies the amount of time (in
    seconds) to wait for the API to run before the
    `SelectorNotFoundException` error is
    thrown. The default value is 30 seconds.
  + `DelayAfter` - Delay time (in seconds) after
    executing the API. The default amount of time is 0.3 seconds
    (300 milliseconds).
  + `DelayBefore` - Delay time (in seconds)
    before the API begins performing any operations. The default
    amount of time is 0.2 seconds (200 milliseconds).

返回值

TrueFalse值取决于是否启用用户界面元素。

此页面有帮助吗?

连接

需要帮助? 支持

想要了解详细内容? UiPath Academy

有问题? UiPath 论坛

保持更新