PureBytes Links
Trading Reference Links
|
You can't open files this way. I think you will need to know the
file names to open specific files. I am not sure how you can get the
names of the files. Then you need to get a handle so you can use the
file and when it is no longer needed close it. If you want to open
all files try a loop putting the file handles in an array. Since you
will get a handle while files are opened and a 0 if one is not
opened track the number of files you open so you know how big the
array is and can close them when you are done.
I am not sure how AB allocates space for an array but try something
like this:
fh[0] = 0; // file handle array
i=0;
for (;;)
{
fh[i] = fopen( "myfile.txt", "w"); //
if( fh[i] )
i = i+1;
else
break; // exits loop when a file is not opened
) // end for loop
// process code
// close files
for (i; i > -1; --i)
(
if( fh[i] )
fclose( fh[i] );
}
Barry
--- In amibroker@xxxxxxxxxxxxxxx, "fox97us" <williamwang97@xxxx>
wrote:
>
> hello,
>
> I have some stock data files in the wrong format. How can I use
> amibroker to do format editing.
>
> I notice that I can use Guru chart commentary to manipulate
files.
> However, when I try to ask the program open all files use
something
> like:
>
>
> fopen( "C:\\Data\\*.txt", "a");
>
>
> the * does not work.
>
>
> Or there is other ways to do it?
>
>
> thanks
>
------------------------ Yahoo! Groups Sponsor --------------------~-->
Try Online Currency Trading with GFT. Free 50K Demo. Trade
24 Hours. Commission-Free.
http://us.click.yahoo.com/RvFikB/9M2KAA/U1CZAA/GHeqlB/TM
--------------------------------------------------------------------~->
Please note that this group is for discussion between users only.
To get support from AmiBroker please send an e-mail directly to
SUPPORT {at} amibroker.com
For other support material please check also:
http://www.amibroker.com/support.html
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/amibroker/
<*> To unsubscribe from this group, send an email to:
amibroker-unsubscribe@xxxxxxxxxxxxxxx
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/
|