I saw this movie 10-15 years ago and can't really remember the details. What I remember is that the protagonists developed some way to achieve temporary clinical death. They are basically trying to find out what is on the other side.
Could it be Flatliners, a 1990 movie starring Kiefer Sutherland, Julia Roberts and Kevin Bacon?
It is about medical students doing exactly what you describe.