tds script