Substr

arrgh, can’t seem to get substr to work properly in this situation. i’m getting

Sun May 13 00:00:00 GMT-0400 2007
back from a query and I want to strip it down to simply say “Sun May 13”.

I’m trying to use:

var dts:String=rs.getItemAt(i).MediaDate;
		trace("DTS: "+dts);
		dta=dts.substr(1, 6);
		trace("dta: "+dta);

to no avail. I get undefined when i try to trace out the substring!

what am i doing wrong???!!!