08-06-2012 04:33 AM
hello everyone
I need to read a number from a webpage. This number is online electricity price which is updated every 5 min. I need to use this price as a parameter in my controller
any suggestion will be appreciated in advance 😄
Reza
Solved! Go to Solution.
08-06-2012 07:32 AM
Simply read the webpage as text file and parse it as mentioned here
08-06-2012 11:36 AM
"Scraping" is regarded as hacking by many sites. Make sure what you are attempting is not violating their Terms of Service (if applicable).
08-07-2012 03:57 AM
Thanks for the reply,
based on what u proposed I can read the page. How can I use a particular number among other irrelevant information? (it reads like 100 lines but I only need to use a number within that text)
Reza
08-07-2012 05:00 AM
Find the line in which the required information is available.
Parse the text using string functions and extract the data.