473,566 Members | 2,958 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

download stock quote from yahoo

f
I am writing an app in which I need to get the stock quote from Yahoo.
Idealy, I will get a stream from Yahoo's web site and parse that as
string and display the information (price, PE, volumn...).

What class should I use?

If you use "http://finance.yahoo.c om/d/quotes.csv?s=YH OO&f=sl1d1t1c1o hgv&e=.csv"
as URL in HttpConnection, you will download a file. How can I obtain a
stream? Is there other URL in Yahoo's site I can get a stream?

Thanks,

ff
Jul 17 '05 #1
6 14331
f wrote:
I am writing an app in which I need to get the stock quote from Yahoo.
Idealy, I will get a stream from Yahoo's web site and parse that as
string and display the information (price, PE, volumn...).

What class should I use?

If you use
"http://finance.yahoo.c om/d/quotes.csv?s=YH OO&f=sl1d1t1c1o hgv&e=.csv"
as URL in HttpConnection, you will download a file. How can I obtain
a
stream? Is there other URL in Yahoo's site I can get a stream?

Thanks,

ff

Jul 17 '05 #2
...hmm. Let's try that again, with some text this time.

Andrew Thompson wrote:
f wrote:
I am writing an app in which I need to get the stock quote from
Yahoo.


Good for you. I am reading a group for
c.l.j.programme r's, where folks are
supposed to already know how to consult
the JavaDocs.

Your message indicates that you have not,
and possibly are unaware of their existence.

Please confine your posts to c.l.j.help
for the moment, at least unitl you can
figure how to use the JavaDocs and
ask smart questions on usenet.

--
Andrew Thompson
* http://www.PhySci.org/ Open-source software suite
* http://www.PhySci.org/codes/ Web & IT Help
* http://www.1point1C.org/ Science & Technology
Jul 17 '05 #3
After that reply you are probably thinking "does everyone in this
newsgroup have a stick up their ****?" The answer is 'no'.

Andrew Thompson, if you can't or don't want to help then just don't
reply to the post, there's no need to bite people's heads off.

f. To answer your question. Try adapting the following code for your
application:

// Read an http resource in to a stream
String tAddress = "http://domain/path/to/resource/file.ext";
URL tDocument = new URL(tAddress);
URLConnection tConnection = tDocument.openC onnection();
tConnection.con nect();
BufferedReader tBufferedReader = new BufferedReader
(new InputStreamRead er(tDocument.op enStream()));

then read the stream as you would with any other BufferedReader object
(keyboard input, for example).

Hope this is a bit more helpful than Andrew's reply.

Andrew Thompson wrote:
..hmm. Let's try that again, with some text this time.

Andrew Thompson wrote:
f wrote:
I am writing an app in which I need to get the stock quote from
Yahoo.

Good for you. I am reading a group for
c.l.j.programme r's, where folks are
supposed to already know how to consult
the JavaDocs.

Your message indicates that you have not,
and possibly are unaware of their existence.

Please confine your posts to c.l.j.help
for the moment, at least unitl you can
figure how to use the JavaDocs and
ask smart questions on usenet.

--
Andrew Thompson
* http://www.PhySci.org/ Open-source software suite
* http://www.PhySci.org/codes/ Web & IT Help
* http://www.1point1C.org/ Science & Technology

Jul 17 '05 #4
f wrote:
I am writing an app in which I need to get the stock quote from Yahoo.
Idealy, I will get a stream from Yahoo's web site and parse that as
string and display the information (price, PE, volumn...).

What class should I use?

If you use "http://finance.yahoo.c om/d/quotes.csv?s=YH OO&f=sl1d1t1c1o hgv&e=.csv"
as URL in HttpConnection, you will download a file. How can I obtain a
stream? Is there other URL in Yahoo's site I can get a stream?

Thanks,

ff


I haven't looked at the yahoo finance page, but I am sure they have a
rss or XML tag somewhere and you can get the quote. I dont much trust
csv or plain text. (that is just me)

Jul 17 '05 #5
Peter Astbury wrote:
After that reply you are probably thinking "does everyone in this
newsgroup have a stick up their ****?" The answer is 'no'.

Andrew Thompson, if you can't or don't want to help then just don't
reply to the post, there's no need to bite people's heads off.

f. To answer your question. Try adapting the following code for your
application:

// Read an http resource in to a stream
String tAddress = "http://domain/path/to/resource/file.ext";
URL tDocument = new URL(tAddress);
URLConnection tConnection = tDocument.openC onnection();
tConnection.con nect();
BufferedReader tBufferedReader = new BufferedReader
(new InputStreamRead er(tDocument.op enStream()));

then read the stream as you would with any other BufferedReader object
(keyboard input, for example).

Hope this is a bit more helpful than Andrew's reply.

Andrew Thompson wrote:
..hmm. Let's try that again, with some text this time.

Andrew Thompson wrote:
f wrote:

I am writing an app in which I need to get the stock quote from
Yahoo.


Good for you. I am reading a group for
c.l.j.programme r's, where folks are
supposed to already know how to consult
the JavaDocs.

Your message indicates that you have not,
and possibly are unaware of their existence.

Please confine your posts to c.l.j.help
for the moment, at least unitl you can
figure how to use the JavaDocs and
ask smart questions on usenet.

--
Andrew Thompson
* http://www.PhySci.org/ Open-source software suite
* http://www.PhySci.org/codes/ Web & IT Help
* http://www.1point1C.org/ Science & Technology

Personally I like the comments, I think they are real and I learn more
if people are direct and to the point as opposed to wishy-washy. We are
programmer, we have thick skins.

Jul 17 '05 #6
f
You are sick and fuck you JavaDocs.
"Andrew Thompson" <Se********@www .invalid> wrote in message news:<xG******* **********@news-server.bigpond. net.au>...
..hmm. Let's try that again, with some text this time.

Andrew Thompson wrote:
f wrote:
I am writing an app in which I need to get the stock quote from
Yahoo.


Good for you. I am reading a group for
c.l.j.programme r's, where folks are
supposed to already know how to consult
the JavaDocs.

Your message indicates that you have not,
and possibly are unaware of their existence.

Please confine your posts to c.l.j.help
for the moment, at least unitl you can
figure how to use the JavaDocs and
ask smart questions on usenet.

Jul 17 '05 #7

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
3341
by: Chris Mosser | last post by:
I'm looking to add a page to my site where I can get stock quotes for the wired, but more importantly, the wireless web(ie my cell phone). I know how write the needed php and WAP application, I just don't know where to get the stock market feed, at least not without parsing a finance.yahoo.com page. Or something else like it that could change...
13
17819
by: dan roberts | last post by:
Folks, This is my first Python project so please bear with me. I need to download data from Yahoo Finance in CSV format. The symbols are provided in a text file, and the project details are included below. Does anyone have some sample code that I could adapt? Many thanks in advance, dan
1
2225
by: plato399 | last post by:
I apologize upfront if this newsgroup isn't the correct place for this question, but it seems to be the most appropriate place. My question is surrounding XML-based web services. I'm trying to get a read on some *real world* use-cases for the Service Oriented Architecture in terms of WSDL,SOAP, etc... I understand all of the concepts and...
1
3185
by: Lorn | last post by:
I'm going to be attempting my most challenging programming task to date and was wondering if I could get some input on what would be the most efficient way of working with stock price quote data for an entire order book. I'm working with a raw text data stream that delivers quotes in realtime for each price level with the quantity of shares,...
7
3014
by: Donlingerfelt | last post by:
I would like to download stock quotes from the web, store them, do calculations and sort the results. However I am fairly new and don't have a clue how to parse the results of a web page download. I can get to the site, but do not know how to request the certain data need. Does anyone know how to do this? I would really appreciate it. ...
5
3341
by: kalyxo | last post by:
Hi all! For one of our web-communities we plan an offer of real time stock quotes incl. advanced notification services. I have the following questions: - Do you know of any services, that already offers such services in a decent way? And more important:
3
2371
by: yuvalbra | last post by:
Does anyone know how to implement a stock quote using ASP on a website? Any sample code or components, etc., would be appreciated. I try this but got error 500 on page strURL = "http://finance.yahoo.com/q?s=MSFT" Set objXMLHTTP = CreateObject("Microsoft.XMLHTTP") objXMLHTTP.open "GET",strUrlAddress, false
3
1662
by: Ganesh | last post by:
Hi There, Not related to asp.net, but someone might have come across this before. I want to download all london stock exchange price end of each day. what's the best source to do that. may be yahoo or some other web site. I cannot find out anything. If so how much would it cost Any idea. Thanks Ganesh
0
7673
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main...
0
7584
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language...
0
7893
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. ...
0
6263
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then...
1
5485
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes...
0
5213
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert...
0
3643
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in...
1
1202
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
926
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.