Look at Graham's code in AFL Library:
http://www.amibroker.com/library/detail.php?id=327&hilite=fputs
The code I posted is based on the above, with a few tweaks to get the data
overwriting properly, to work with Watch Lists and to get MS format. You will
need to:
1) replace periodicity code "D" with "I" (or remove this altogether, depending
on which version of MS you have)
2) add "time string" variables: r, e, n
3) add two "time string" lines after "date string":
ts = StrFormat("%02.0f:%02.0f:%02.0f,", r[ i ],e[ i ],n[ i ] );
fputs( ts, fh );
In case you want to have 4-digit year replace:
y = Year()%100;
with
y = Year();
If you look closer at both examples you should be able to figure out how all
this works.
The code with % signs is C++ printf() specifier:
http://www.cplusplus.com/reference/clibrary/cstdio/printf.html
Please keep in mind that AFL doesn't support integers, that's why everything is
coded as a "float".
Lester
--- In [email protected], "cas" <[EMAIL PROTECTED]> wrote:
>
> SIR,
> THANK YOU VERY MUSH FOR THE CODE
> PLS ONE MORE REQUEST IF I WANT TO CONVERT INTRA DAY DATA FROM ASCII TO
> METASOCK ....WHAT LINES I HAVE TO ADD...PLS HELP THANK YOU