Put+the+contents+of+file+into+a+String

Here is an easy way to put an entire file into a string:

code format="lb" open "filename.txt" for input as #filein filestring$ = input$(#filein, lof(#filein)) close #filein code