i want attach a specified filetype to my own program. so if i doubleclick on a file from that type, it should open my program, an i should be able to use the content of that file in my program

How can I do this? please help me