01-14-2011 11:37 AM
When I try to run the code below, I get an error message saying "Error 1 occured at Open File." Please help. Thanks!
01-14-2011 11:50 AM
Is the path in your SaveFile indicator valid and do you have access to the file? Error 1 is typically an invalid path error.
As a side note, you probably don't need all of those local variables.
01-14-2011 02:44 PM
The SaveFile is valid. I just found out the "Write Characters to File.vi" is no longer valid in labview. There is also another vi "Write to SGL File" that appears to be invalid. This is probably the issue. What functions can I replace these blocks with? Thanks.
01-14-2011 02:49 PM
Read/Write text file is probably what you're after.
/Y
01-14-2011 03:03 PM
What about "Write to SGL File"?
01-17-2011 12:00 PM - edited 01-17-2011 12:00 PM
Hey Krang,
If I understand the history of that function correctly, we switched from a set of read/write vis for every data type to a smaller set. The LV7.1 help documentation says that read/write sgl file is just converting a single precision number to the binary representation and then outputting that to a file.
To replace that, you would use the read/write binary file VI. An example of this can be found here. The key point is that when you read in the binary data, you have to specify the type by attaching a single precision numeric constant to the data type input. You do not need to specify the data type for write to binary file.
Thanks,
D. Smith