Getting a folder item - newbie question

I want to have the user choose which file they want to open. This is probably easy but I can’t find good documentation on it. Thanks. Also if you could point me to some good documentation on the web I’d appreciate it. All I really know how to do right now is to record scripts.

Okay I figured that part out but I keep getting the following error:
“QuickTime Player got an error: A descriptor type mismatch occurred.”
when I get to the end of my script. I want to add a text track to my video. It seems to open up everything until it gets to
" select all file mainMovie" where I select all of the movie track before adding the text track.

tell application “QuickTime Player”
select all movie “data.txt”
open file “Macintosh HD:Users:pat:Sites:slides:data.txt”
copy movie “data.txt”
close movie “data.txt” saving no
set mainMovie to choose file of type “MooV” with prompt “Find your recorded movie:”
display dialog “opened”
select all file mainMovie
add movie mainMovie