I have a URL to some media data that I want the user to watch/listen to. I also want Rev to just launch whatever application the user has bound to that file type. I can't just use the start command in shell() because - since the "file" is a URL - it will just launch IE (or whatever the default browser is) and many times it will prompt the user to download the media, which I don't want.
So, to get the associated application with the file, I've done the following (comments welcome if there's an easier way to do this):
Code: Select all
set the itemDelimiter to "."
-- get the file extension (lower cased)
get the lower of the last item of tURL
-- get the command line required to open the file of this file
get queryRegistry("HKEY_CLASSES_ROOT\" & it & "\")
get queryRegistry("HKEY_CLASSES_ROOT\" & it & "\shell\open\command\")
Code: Select all
c:\program files\quicktime\quicktime.exe "%1"
So, the question is: how can I figure out what exactly is the "program" in the command returned from the registry so I can quote it? Better still, anyone know of any other way of getting the application associated with a file type aside from bouncing around in the registry?
Jeff M.