Is there anyway to open a file in an application. So specify the application and then open a file with it?

Thanks