Author Topic: Stock Chart Downloading  (Read 5153 times)

uk_skinner

  • Global Moderator
  • TodayPlus Veteran
  • *****
  • Posts: 1313
Stock Chart Downloading
« on: October 05, 2004, 09:04:05 PM »
nas brought out this interesting idea: to download the stock chart and displayed in TP.  Since we are developing the exe to download the weather image, there is no reason that we cannot do it for the stock chart.  However, it will be very difficult to get a realtime quote/chart for free.  If you have any idea, please post here and we can try to put something together.

Wichtel

  • Global Moderator
  • TodayPlus Veteran
  • *****
  • Posts: 550
Stock Chart Downloading
« Reply #1 on: October 06, 2004, 12:39:12 AM »
I have imagined exactly something like that when I asked for it yesterday  I would like this to store pictures into a different folder.

I would like this to accommodate stock charts in the RSS section. The links Given this one to Nas have the perfects contain picture size.

nas

  • TodayPlus User
  • **
  • Posts: 32
Stock Chart Downloading
« Reply #2 on: October 06, 2004, 02:20:13 AM »
This Chart from Yahoo ist possible in/for Germany too.

But I prefer for Germany the URL we talked about yesterday in the chat (www.finanztreff.de), because there are more information on the image (market price now, high, low, yesterday, sales Volume).

nas

uk_skinner

  • Global Moderator
  • TodayPlus Veteran
  • *****
  • Posts: 1313
Stock Chart Downloading
« Reply #3 on: October 06, 2004, 05:49:10 AM »
Quote from: "nas"
This Chart from Yahoo ist possible in/for Germany too.

But I prefer for Germany the URL we talked about yesterday in the chat (www.finanztreff.de), because there are more information on the image (market price now, high, low, yesterday, sales Volume).

nas


Does this site provide stock quote for USA market?  If it does, is it 15 min delayed?

Edit:  Here is NASDAQ chart from www.finanztreff.de

nas

  • TodayPlus User
  • **
  • Posts: 32
..first try
« Reply #4 on: October 06, 2004, 06:10:39 AM »
Hi,

I tried ist with Disney (...Image). But the side is in german language.
It delayed 20 Min.

The German charts delayed 15 Min. Realtime is very rare and you have to pay for it (mostly).  Some realtime-chart are free, but the stock market place is then mostly less important.

nas

nas

  • TodayPlus User
  • **
  • Posts: 32
Stock Chart Downloading
« Reply #5 on: October 06, 2004, 07:07:58 AM »
EDIT: Change above "Most realtime charts..." in "Some realtime cahrts".

I try to find a realtime chart in germany. I don´t find one during the last hour. I only find quotes (text-information).

uk_skinner

  • Global Moderator
  • TodayPlus Veteran
  • *****
  • Posts: 1313
Stock Chart Downloading
« Reply #6 on: October 06, 2004, 10:17:16 AM »
Rotlaus:  I was trying to see I can use your exe to download a csv file from yahoo.  The txt file looks like this.

SURL=http://finance.yahoo.com/d/quotes.csv?s=^DJI&f=sl1d1t1c1ohgv
STOR=/Programme/TodayPlus/Images/Radar/wetteronline/dji.txt
FORM=

But I got error message (see screenshot).  Any idea?  EzDownload worked fine to download information.  Right now it is possible to display the quote, although it is delayed one.

Rotlaus

  • TodayPlus User
  • **
  • Posts: 58
Stock Chart Downloading
« Reply #7 on: October 06, 2004, 03:34:05 PM »
Quote from: "uk_skinner"

But I got error message (see screenshot).  Any idea?  EzDownload worked fine to download information.  


The problem is, the web server you mentioned is transfering in chunked transfer-mode, so i cannot obtain the amount of data that will be transfered. I'll put a version in the Attachement that works with the url, but the progress bar will not work anymore.

uk_skinner

  • Global Moderator
  • TodayPlus Veteran
  • *****
  • Posts: 1313
Stock Chart Downloading
« Reply #8 on: October 07, 2004, 04:25:57 PM »
Rotlaus:

    I am trying to see I can read the data from the file that was downloaded using your exe.  The contents of files looks like this:

"^DJI",10239.92,"10/6/2004","4:03pm",+62.24,10170.70,10240.14,10157.99,232016448

I was folling around and tried to use "fwscanf" to read it.  As you can see the format of the data is "csv".  Do you know how can use "fwscanf" to read the data between "," or you have better way to do.  Thanks.

Rotlaus

  • TodayPlus User
  • **
  • Posts: 58
Stock Chart Downloading
« Reply #9 on: October 08, 2004, 03:39:01 AM »
Quote from: "uk_skinner"

I was folling around and tried to use "fwscanf" to read it.  As you can see the format of the data is "csv".  Do you know how can use "fwscanf" to read the data between "," or you have better way to do.  Thanks.


String handling in C is a real pain. That was one reason why i changed my development system to .NET, especially using the C# Language. There i can do things like this:

Code: [Select]
string info = "mark;smith;123 csharp drive;toronto;canada";

    string[] arInfo = new string[4];
   
    // define which character is seperating fields
    char[] splitter  = {';'};
           
    arInfo = info.Split(splitter);


At the end i have an array (arInfo[]) which contains the seperated elements of the String.

You could try something like this:
Code: [Select]
fwscanf(stream,"%s,%f,%s,%s,%f,%f,%f,%f,%ld", string1, float1, string2, string3, float2, float3, float4, float5, double1);

But I have no idea if this will work.


Andre

uk_skinner

  • Global Moderator
  • TodayPlus Veteran
  • *****
  • Posts: 1313
Stock Chart Downloading
« Reply #10 on: October 10, 2004, 10:59:00 AM »
Rotlaus:  Thanks for the help.  You are right!  It is very painful to figure out how to get this code right.  But I finally got it out.

fwscanf( stream, L"%[^ ,],%f,%[^ ,],%[^ ,],%f,%f,%f,%f,%d[^ ,/n]", symbol, &quote, date, update_time, &change, &pre_close, &day_h, &day_l, &volume);

So far, I can..
1) Download the information from yahoo.com for each stock.
2) All the information will be consolidated into only one text file.
3) Read the quote, day-high, day-low, volume, updated date and time for each one.


I am still struggle to put on the windows... :wall:

This will be a big task for me to learn how to create a window and display the data and no idea how long will take me..


nas, or anyone, can you let me know is there any other site just like yahoo, allow you download the quote information as text or csv format?  I would like to test them too..  Thanks.

nas

  • TodayPlus User
  • **
  • Posts: 32
...sorry, no...
« Reply #11 on: October 10, 2004, 12:15:32 PM »
Hi uk_skinner,

I have searching for a while but I don´t find and know another site just like Yahoo yet.

The text-quotes I know are only indicated, a download as text or csv is not possible.

Some sides offer only the download of a printfile (for example
http://aktien.onvista.de/times_sales.html?ID_NOTATION=5397979).
But I don´t know how to download such files.

Many greetings.

nas