ok I see my dumb ass mistake now the length property int he mid$ should have been 1 instead of i.