Blame view

src/idl_misc/JPBLib_for_Dustemwrap/General/file2strings.pro 246 Bytes
6db3528a   Jean-Philippe Bernard   adding librairies...
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
FUNCTION file2strings,filename,nlines=nlines

openr,unit,filename,/get

strs=['']
str=''
WHILE not eof(unit) DO BEGIN
  readf,unit,str
  strs=[strs,str]
ENDWHILE
strs=strs(1:*)
nlines=n_elements(strs)

close,unit

free_lun,unit

RETURN,strs

END