Asset

更新时间:
复制 MD 格式

get_value

get_value(name)

Description

Retrieves the value of a specified asset. You must have permission to use the asset.

Parameters

name<str> The name of the asset.

Example- rpa.console.asset.get_value-

account = rpa.console.asset.get_value('test_account')
Note

For details about creating and using assets, see privacy data processing.

Important
  • This method only supports 'text' and 'password' assets.

  • The method throws an exception if the account running the application lacks permission to use the asset.

fill_account_to_page

fill_account_to_page(name, user_element, password_element, page, wait_mili_seconds=20)

Description

Fills the username and password elements on a web page using an 'account and password' asset.

Parameters

name<str> The name of the asset.

user_element<str> The username element.

password_element<str> The password element.

page<object> The target browser page object.

Example- rpa.console.asset.fill_account_to_page-

page = rpa.app.chrome.create(r'login.taobao.com/member/login.jhtml')
rpa.console.asset.fill_account_to_page('my_taobao', 'username-selector', 'password-selector', page)
Note

For details about creating and using assets, see privacy data processing.

Important
  • This method only supports 'account and password' assets.

  • The password element must be a password input field, such as an <input type="password"> element.

  • The method throws an exception if the account running the application lacks permission to use the asset.