1

In this link answer in line 6, how to identify how many getElement("div") and getElements("div")[number] should be captured from a URL.

This is the URL from where I am looking to capture the table.

Community
  • 1
  • 1
Vasim
  • 3,052
  • 3
  • 35
  • 56

2 Answers2

6

You may want to look into using import.io, which is a tool specifically for extracting tabular data from web pages, and which has an Apps Script integration.

Eric Koleda
  • 12,420
  • 1
  • 33
  • 51
0

another example could be to pull the table into Sheets and the access the data from within the Sheets. For example:

=importhtml("http://www.tradingeconomics.com/zambia/rating","table",1)

This pulls the first table on the particular webpage into the sheet.

Jan Krynauw
  • 1,042
  • 10
  • 21