Re: string read [message #71551] |
Mon, 28 June 2010 03:21 |
kamal
Messages: 12 Registered: June 2010
|
Junior Member |
|
|
I suppose the problem is with the Function dms2d.
What exactly does this function do?
|
|
|
Re: string read [message #71553 is a reply to message #71551] |
Mon, 28 June 2010 00:30  |
Wout De Nolf
Messages: 194 Registered: October 2008
|
Senior Member |
|
|
"dat" is just a string, not a string array with 8 elements. To convert
it to a string array you could do something like this:
dat2=strsplit(dat,"',",/extract)
On Sun, 27 Jun 2010 22:29:19 -0700 (PDT), dolly
<gaurijyoti29@gmail.com> wrote:
> OPENR, unit, 'd:\data.txt'
> d=fltarr(8)
> dat = ' '
> for i=0,3 do begin
> READF, unit, dat
> print,dat
> for j=0,7 do begin
> d[j]=dms2d(dat[j])
> print,d[j]
> endfor
|
|
|