Сравнение версий

Ключ

  • Эта строка добавлена.
  • Эта строка удалена.
  • Изменено форматирование.

...

The frame (the one switched to) contains two frames.

2. Опция Текущий фрейм - ищем фрейм в внутри текущего фрейма. Переключимся на фрейм с текстом "This The Current frame option - search for a frame inside the current frame. Let's switch to the frame with the text “This is main page and content from any link will be displayed here". Это второй фрейм внутри текущего фрейма. Укажем параметры действия:
here”. This is the second frame inside the current frame. Let's specify the action parameters:

    • Specify the open browser context in the "Context" field.
    • Specify 1 in the "Index" field (frame numbering starts with 0).
    • Specify value "Current frame" in the "Frame search area" field (search for a child frame in the current frame
    • в поле "Контекст" укажем контекст открытого браузера,
    • в поле "Индекс" укажем значение 1 (нумерация фреймов начинается с 0),
    • в поле "Область поиска фрейма" укажем значение "Текущий фрейм"  (ищем дочерний фрейм в текущем фрейм).

 
 

Далее, с помощью действие "Получить текст" получим текст из фрейма (см. приложенную к описанию схему роботаNext, use the "Get Text" action to get the text from the frame (see attached robot scheme).

3. Опция Вся страница -  выполним переключение фокуса из фрейма на основную страницу. Для этого указываем опцию "Вся страница" и контекст открытого браузера. Остальные параметры оставьте пустымиThe Entire page option -  let's switch the focus from the frame to the main page. To do this, specify the "Entire page" option and the context of the open browser. Leave the other parameters empty

Выполним действие "Получить текст" из основной страницы (см. приложенную к описанию схему роботаLet's run the "Get Text" action from the main page (see attached robot scheme). 

...

Task 2

Зайти на сайт с фреймом Go to website with a frame https://www.w3schools.com/css/tryit.asp?filename=trycss_default, переключиться на него для дальнейшей работы с ним и получить текст из фрейма switch to it for further work with it and get the text from the "My First CSS Example" frame. 

Реализовать действие с использованием параметров "ИмяImplement the action using the "Name", "ЭлементElement" и опций "Область поиска".

Решение

Воспользоваться действиями "Открыть браузер", "Переключиться на фрейм", "Получить текст". 

Реализация

parameters and "Frame search area" parameter option.

Solution

Use the "Open browser", "Switch to frame", "Get text" actions.

Implementation

  1. Assemble a robot scheme with the actions.
    Image Added
  2. Set the "Open browser" action parameters.
    Image Added
  3. Set the "Switch to frame" action parameters.
    Image Added
  4. Set the "Get text" action parameters. In the "Element" field specify the element from which you want to get the text. More about creating elements in section:
  5. Собрать робота, состоящего из действий:
    Image Removed
  6. Настроить параметры для действия "Открыть браузер". 
    Image Removed
  7. Настроить параметр для действия "Переключиться на фрейм". 
    Image Removed
  8. Настроить параметры для действия "Получить текст". В поле "Элемент" необходимо указать элемент из которого необходимо получить текст. Подробнее о создании элементов в разделе: Create Web-elements

  9. Нажать на кнопку Click "Старт" в верхней панели. 

Результат

Программный робот отработал успешно. 

Image Removed

  1. Start" in the top panel.

Result

The program robot completed successfully.

Image Added

In this case, if you disable the "Switch to frame" action, the item will not be found because the item is searched for in the current document, but the item itself is in a nested document.В данном случае, если отключить действие "Переключиться на фрейм", то элемент не будет найден,  так как поиск элемента осуществляется в текущем документе, а сам элемент находится во вложенном.