Gamestudio Links
Zorro Links
Newest Posts
Zorro 2.70
by jcl. 09/29/25 09:24
optimize global parameters SOLVED
by dBc. 09/27/25 17:07
ZorroGPT
by TipmyPip. 09/27/25 10:05
assetHistory one candle shift
by jcl. 09/21/25 11:36
Plugins update
by Grant. 09/17/25 16:28
AUM Magazine
Latest Screens
Rocker`s Revenge
Stug 3 Stormartillery
Iljuschin 2
Galactic Strike X
Who's Online Now
1 registered members (TipmyPip), 18,619 guests, and 5 spiders.
Key: Admin, Global Mod, Mod
Newest Members
krishna, DrissB, James168, Ed_Love, xtns
19168 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
File reading and writing #429740
09/17/13 18:34
09/17/13 18:34
Joined: Jun 2013
Posts: 41
Ohio, USA
P
Pork Offline OP
Newbie
Pork  Offline OP
Newbie
P

Joined: Jun 2013
Posts: 41
Ohio, USA
There is an old thread that talks about opening a file using windows fopen. This includes an example and the example works.
the thread is here
Can someone point me to an explanation of how to read a line of text from the file that you opened? Or how to use the windows file commands in stdio.h or windoes.h files in Zorro.
I've spent most of the last two days trying to figure this out.
Read more ways than I care to admit about how to read a line from a file in both c++ references and windows references, but I can't make it work.
The file functions in zorro don't seem to be helpful either.
You can read the entire file. Then use string functions to find what you want? That seems extreme.
I'm making progress, but still running into obstacles.
Thanks
P

Re: File reading and writing [Re: Pork] #429770
09/18/13 11:03
09/18/13 11:03
Joined: Jul 2000
Posts: 28,024
Frankfurt
jcl Offline

Chief Engineer
jcl  Offline

Chief Engineer

Joined: Jul 2000
Posts: 28,024
Frankfurt
You can find a short script example how to read numbers from a file in the "string functions" chapter. Reading lines instead of numbers should be not very difficult, depending on what you want to do with those lines.

A more complex example for reading data from the data fields of a spreadsheet file can be found here (under "Special data export/import"):

http://manual.zorro-trader.com/export.htm

Re: File reading and writing [Re: jcl] #429787
09/18/13 15:47
09/18/13 15:47
Joined: Jun 2013
Posts: 41
Ohio, USA
P
Pork Offline OP
Newbie
Pork  Offline OP
Newbie
P

Joined: Jun 2013
Posts: 41
Ohio, USA
Thanks JCL,
That's very helpful. Did not see it before.
P


Moderated by  Petra 

Gamestudio download | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1