hello
better yet when you open the random file you use
zcustrecnum = lof(1) /lcustreclen.. if there is not records in the file this should be 0.
when the record insertion module or sub is call all you need is
zcustrecnum = zcustrecnum +1
put #1,zcustrecnum, custinforec
it seems to work fine.
Badger