Rename files in a folder?

hi dynapips,

im trying to rename existing file using dynamo, but i cant get it to work. Any ideas?

import sys
pyt_path = r'C:\Program Files (x86)\IronPython 2.7\Lib'

import os

files = IN[0]
newNames = IN[1]

nfiles = []

for i, n in zip(files,newNames):
	newfile = os.rename(i, n)

OUT = nfiles

You have to feed it an entire path name, not just a file name. Right now you are just sending in two bits of text and it has no idea what to do with it.