fpng = findfile('*.png') nn = n_elements(fpng) strtempl = {date_obs:'', date_end:'', jt_obs:0D, jt_end:0D, pngfilename:'', txtfilename:''} struct = replicate(strtempl, nn) ;--- fill struc --- for i=0, nn-1 do begin f = fpng[i] struct[i].pngfilename = f ss=strsplit(f, '_.', /extract) ftxt = 'hard_rad_'+ ss[2] +'_'+ss[3]+'.txt.gz' struct[i].txtfilename = findfile(ftxt) ; if check ne '' then stop date_obss = '20'+strmid(ss[2], 0, 2) +'-'+ strmid(ss[2], 2, 2) +'-'+ strmid(ss[2], 4, 2) date_ends = '20'+strmid(ss[3], 0, 2) +'-'+ strmid(ss[3], 2, 2) +'-'+ strmid(ss[3], 4, 2) struct[i].date_obs = date_obss struct[i].date_end = date_ends date_obs = date_obss+'T00:00:00.000' date_end = date_ends+'T00:00:00.000' struct[i].jt_obs = sphinx_datetime2jt(date_obs) struct[i].jt_end = sphinx_datetime2jt(date_end) ;print, i,' ', f, ' ', date_obss, ' ', date_ends, ' ',struct[i].txtfilename print, i,' ', f, ' ', date_obs, ' ', date_end, ' ',struct[i].txtfilename endfor ;---------------- select only images which have txt data --- w = where(struct.txtfilename ne '') struct = struct[w] nn = n_elements(struct) for i=0, nn-1 do begin print, i,' ', struct[i].pngfilename, ' ', struct[i].date_obs, ' ', struct[i].date_end, ' ',struct[i].txtfilename, ' ', $ struct[i].jt_obs, struct[i].jt_end, struct[i].jt_end-struct[i].jt_obs endfor ;--- sort by jt -- struct = struct[sort(struct.jt_obs)] ;------- close, /all A='' openr, 1, 'RESIK_PIN_particle_observations_template.htm' openw, 2, 'RESIK_PIN_particle_observations.htm' while a ne '' do begin readf, 1, A printf, 2, A endwhile ;---- insert images into html table ncol=2 nrow=ceil(double(nn)/2) cimg=0 printf, 2, '
' printf, 2, '' for i=0, nrow -1 do begin printf, 2, '' for j=0, ncol-1 do begin printf, 2, '' ;insert images cimg =cimg+1 endfor printf, 2, '' endfor ; ; ; ; ; ; ; ; printf, 2, '
' ;printf, 2,string(i+1)+string(j+1) ;' printf, 2, 'Pulpit rock
' printf, 2, 'Download RESIK data
' printf, 2, '
; Pulpit rock
; Download RESIK data
; row 1, cell 1
; Pulpit rock
; row 1, cell 2
row 2, cell 1row 2, cell 2
' printf, 2, '
' printf, 2, '
' printf, 2, '

ACKNOWLEDGEMENT

' printf, 2, '

The research leading to these results has received funding from the European Commission'+ string(39B) +'s Seventh Framework Programme
' printf, 2, '(FP7/2007-2013) under the grant agreement eHeroes (project no 284461, www.eheroes.eu).

' printf, 2, '
' printf, 2, '' printf, 2, '' close, /all end