function cdf_parse_epoch3,str
	; Function parses an epoch string of the CDF epoch3 format
	; and returns the numerical epoch value.  This epoch3 format
	; is very close to the format of DATE_OBS in the SXI FITS header.
	; The only difference is that Epoch3 has a 'Z' at the end.
	; 		Epoch3 format is: YYYY-MM-DDTHH:MM:SS.cccZ
	; (T and Z are literals)
	; ccc is milliseconds

	ep = 0.0D & ss=0 & ccc=0
	str = strtrim(str,2)
	len = strlen(str)
	strput,str,"-",4
	strput,str,"-",7

	;print,'in cdf_parse_epoch3: str=',str
	yr = fix(strmid(str,0,4))
	mo = fix(strmid(str,5,2))
	dom = fix(strmid(str,8,2))
	hh = fix(strmid(str,11,2))
	mm = fix(strmid(str,14,2))
	if len eq 23 then begin
		ss = fix(strmid(str,17,2))
		ccc = fix(strmid(str,20,3))
	endif
	;print,yr,mo,dom,hh,mm,ss,ccc
	cdf_epoch,ep,yr,mo,dom,hh,mm,ss,ccc,/compute
	return,ep

end