![]() |
|
#3
|
|||
|
|||
|
Cheers Jeff - you're a star! I have got another problem though - all of a sudden the output data will not write to the specified file - it was fine and then suddenly stopped working. The code I have is as follows:
Code:
directory = 'Y:\backup\Vizard30\resources\road' subjectd = 'speed_.txt' + str(subject) filename = directory+subjectd file = open(filename, 'w') def mytimer (num): out = (str(round(speedm,1)) + '\n') file.write(out) file.flush() print out viz.callback( viz.TIMER_EVENT, mytimer ) viz.starttimer( 0, 0.25, viz.FOREVER ) Traceback (most recent call last): File "<string>", line 11, in ? File "roadldstop.py", line 167, in ? file = open(filename, 'w') IOError: [Errno 2] No such file or directory: 'Y:\x08ackup\\Vizard30\resources\roadspeed_.txt222 2' I know the path exists so is this message because it's trying to create a temporary file when outputting the data? |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| split screen | honey006 | Vizard | 3 | 05-21-2009 09:57 AM |
| Remove the credits on the run screen | Saz | Vizard | 1 | 11-21-2008 09:01 AM |
| screen image | erchrastil | Vizard | 8 | 06-27-2008 11:45 AM |
| position of html-file on screen | active_world | Vizard | 1 | 05-16-2008 07:24 PM |
| accessing screen buffer | hotspur1 | Vizard | 3 | 08-22-2003 03:31 PM |