templObj was not declared