Random Access Files

derlwyn

Registered User.
Local time
Today, 14:45
Joined
Mar 21, 2003
Messages
12
I am trying to write records to a random access file

All string fields in the record are of fixed length

From time to time I get an error "bad record length runtime error 59"

These appear to occur at random, I fix some od the code and they dissapear only to appear next time I try to use the file

I have checked the syntax of the program, and all seems fine

I am using LEN(recordname) to tell the PC of the size of the records on the file

Any ideas on how to fix this

Thanks
 
What type of data are you writing? and what type of file are trying to create? plus what method are you using to create these files?

David
 
The data is a collection of strings (all fixed length), boolean, integer and date types

The file type is a DAT type

I am using PUT to write to the file and GET to read from it

Thanks
 
Can you lost a sample of the code you are using?

You may want to try Open File of Input/Output As #1 method.

David
 

Users who are viewing this thread

Back
Top Bottom