I'm not completely sure about JScript, but I do know that Cells(0,11)
shouldn't work because cells is base 1 (there is no Row 0 in Excel). So, if you try changing your code to:
for(i=1; i<wks.UsedRange.Rows.Count; i++)
I believe it will work. I could be wrong, but it's worth a shot.