how to read a range of text in a UI and export it

how to read a range of text in a UI and export it

Home Forums Ask Expert how to read a range of text in a UI and export it

  • This topic has 1 reply, 2 voices, and was last updated 6 years ago by Sasha ZAP.
Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #32227
    Ariel Cairo
    Participant

      Hi,

      just starting on Zap test, i have a small assignment wherein i will have to view a certain webpage which contains txt, how can i make zaptest read not just 1 line, but 5 to 10 lines or more, and how i can it be exported to excel.

      Attachments:
      #32229
      Sasha ZAP
      Moderator

        Hello ryhelcairo,

        In order to get more the 1 line of text from a single object and save it to an Excel file you can do as follow:
        1. Scan the GUI using “Scan Multiline” (Right to the Scan GUI button there is a small arrow, when you click on it you will see different scanning GUI types).
        2. This is an example code how to getting an object’s multiline text and saving it to an Excel file:

        ZAP.Datatable.ImportExcel(“C:Test.xls”)
        strData = Application(“Application”).View(“View”).Object(“Multiline Text Object”).GetText
        ZAP.Datatable.SetValue “Name of Spreadsheet Columns”, strData
        ZAP.Datatable.ExportExcel(“C:Test.xls”)

        P.S. In order to get started with ZAPTEST please visit the “ZAPTEST Beginner Tutorial” page at:

        Tutorial

        Hope this helps.

        Thanks,
        ZAPTEST Team

      Viewing 2 posts - 1 through 2 (of 2 total)
      • You must be logged in to reply to this topic.

      Virtual Expert

      ZAPTEST

      ZAPTEST Logo