Announcement

Collapse
No announcement yet.

write/read file

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • write/read file

    Is EFS able to read from/write to a file?
    If yes, is there any documentation and samples out there.
    Thank you in advance.

  • #2
    yes u can

    here is what i do..

    function main(){

    // FILENAME WILL LOOK LIKE ES-MM-DD-YYYY.txt
    Log1 = sym+"-"+ my_month + "-" + my_day + "-" + my_year+".txt";
    f1 = new File(Log1); // PUT IT IN FORMULA OUTPUT
    f1.open("a+");

    if(!f1.isOpen())
    {
    debugPrintln("*** Couldn't open TRADE LOG!");
    }else
    {
    debugPrintln("*** "+sym+" TRADE LOG OPEN");
    }

    f1.writeln(".Short.Reversal.Cancel.All");

    // CLOSING THE LOG FILES
    if(f1.isOpen())
    {f1.close();}

    Comment


    • #3
      Some amount of documentaion is HERE

      fileformularef.doc is the file you want.

      Also, there are formula example of how to use this in your local formula's directory. I think it is under "other", but I don't have eSignal running where I am right now to verify.

      G
      Garth

      Comment

      Working...
      X