Note that you should NOT select the textrange too.

It is hardly ever necessary to select and will often throw errors if the object is not selectable (eg if it is on a non active slide)