Hi Charles,
(string File) is an error, an evil error of the programmer.
Sub SaveFile(Byval File as string,byref dest as any, byval count as long) 'saves lovely
sys FileHandle
FileHandle = CreateFile(File, GENERIC_WRITE, FILE_SHARE_WRITE, BYVAL 0, OPEN_ALWAYS, 0, 0)
WriteFile FileHandle,dest,count,&dwcount, Byval 0
CloseHandle FileHandle
End Sub
Sub SaveFile(string File, byref dest as any, byval count as long) 'does not save
sys FileHandle
FileHandle = CreateFile(File, GENERIC_WRITE, FILE_SHARE_WRITE, BYVAL 0, OPEN_ALWAYS, 0, 0)
WriteFile FileHandle,dest,count,&dwcount, Byval 0
CloseHandle FileHandle
End Sub