Can someone correct this code it is not working!

set the this_folder to (choose folder with prompt “Please select the folder which contains the Indesign files to convert”)
set the open_folder to the POSIX path of this_folder
on error
set the this_folder to path to desktop as alias
end try
tell application “Finder” to set the_files to every file of the this_folder whose name extension is “qxp”
repeat with oneFile in the_files
tell application “System Events”
tell process “QuarkXPress”
delay 5
tell application “QuicKeys”
play shortcut named “ID2Q Open”
end tell
end tell
tell window “Convert InDesign® Document”
keystroke “G” using {command down, shift down}
repeat until exists sheet 1
delay 0.5
end repeat
tell sheet 1
keystroke open_folder
delay 4
end tell
end tell
end tell
end repeat