Continue to Site

Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

  • Congratulations MintJulep on being selected by the Eng-Tips community for having the most helpful posts in the forums last week. Way to Go!

Write frame.description in a text file

Status
Not open for further replies.

Eleo

Mechanical
Mar 2, 2015
26
How to write in a text file the following data:
Increment 0: Step Time = 4.2613E-06

Increment 100: Step Time = 4.2613E-04

I used the code:
file.write('%s %d %s %s %6.4f \n '(frame.description[0],
frame.description[1],frame.description[2],frame.description[3],
frame.description[4]))

I have the error message TypeError: ‘str’ object is not callable.
 
Replies continue below

Recommended for you

I have just used the following code and it is working ok.
file.write('%s \n '%(frame.description))
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor