Print File Function

Hi

does anybody know if I can do this with the print file function

print(file("c:\test.txt"),"testing 123");

do something

print(file("c:\test.txt"),"testing 456");

do something

print(file("c:\test.txt"),"testing 789");


Basically this will out a test.txt. I do not want the line to be appended.
testing123
testing456
testing789


what I want is basically 1 line for each function that it have perform without appending the file.

I try to use a filedelete function but it doesnt work as the file is being open so it cannot be deleted.

Any advise is much appreciated.

Thank you
 
Quote from Chicken Little:

Why not hard code a different file name for each line ?

oh I should have mention this. I am using Bracket-Trader Automating Trading System

it basically understand only 1 line or the first line of text and 1 filename also.

So if the file get appended the 2nd order cannot be send.

What I want to do is this

if condition is met

create the file ... ... (bracket trader will issue the signal as long as this file is created)

delete file or content of the file

create the file again same filename (bracket trader will issue next signal)

... ...

any advice
 
Quote from Chicken Little:

Are you using tradestation to generate the file ?

I am using Multicharts to be exact. Multicharts coding and tradestation is the same coding so it will work tradestation support what I want.
 
Back
Top