args List, Template, Delim local fh = file.open(List, "r") static Slash = "\" local LT = length(Template) local Path, Name, i, Dir, Str, Depth, NewName, Ext, Char if(fh > 0) do for(not(file.eof(fh))) Str = file.readstring(fh) if(Str) do Path = file.folder(Str) ++ Slash Name = file.name(Str) Ext = "." ++ file.type(Str) Depth = word(Path, 0, Slash) NewName = Name for(i = LT; i > 0; i--) Char = Template[i - 1] Dir = word(Path, Depth - Char + 1, Slash) NewName = Dir ++ Delim ++ NewName endfor endif file.rename(Path ++ Name ++ Ext, Path ++ NewName ++ Ext) endfor else messagebox("ok error", "File not opened", "FILE plugin error") endif file.close(fh)