Parth Bhatt
Parth Bhatt

Reputation: 19469

How to retrieve data from Yahoo Finance to my website?

I am making an ASP.NET website where I want to retrieve data from Yahoo Finance, e.g.:

http://finance.yahoo.com/d/quotes.csv?s=RHT+MSFT&f=sb2b3jk

I am referring to above link to fetch data from Yahoo Finance.

The above link gives data in CSV format.

So how can I fetch data from the above link into my website? Any code or reference to some tutorial would be of great help.

Upvotes: 1

Views: 1523

Answers (2)

Parth Bhatt
Parth Bhatt

Reputation: 19469

Got the answer.

Used System.Net.WebRequest to download the CSV and then parsed it using answer in below link.

How to parse a CSV file in an ASP.NET website?

Hope this helps someone.

Upvotes: 2

Wyatt Barnett
Wyatt Barnett

Reputation: 15663

Use the System.Net.WebClient to request the CSV, then something like FileHelpers to parse the file into a usable object. Then stuff into whatever you want.

Upvotes: 2

Related Questions