Reverse string or list

Hi Scripting Gods,
Still new to Applescript.
Is there a way to reverse a list or string or alias so I can get the reverse order of a file/folder location?

eg
“UserSpace:Users:UserName:Desktop:TestApp:folder_Folder:Personal Folders:Deleted Items” to
“Deleted Items:Personal Folders:folder_Folder:TestApp:Desktop:UserName:Users:UserSpace”

The folder’s location and name (etc) is variable.

Thanx in advance

Hi,

something like this


set thePath to "UserSpace:Users:UserName:Desktop:TestApp:folder_Folder:Personal Folders:Deleted Items"
set {TID, text item delimiters} to {text item delimiters, ":"}
set thePath to reverse of text items of thePath as Unicode text
set text item delimiters to TID

Thanx Stefan,
Has done the trick.
I had “words” instead of “text items”.

much appreciated.