net.openURL : Windows can't open file

Hi everybody !

I’ve created a script which open a pdf like this :

path = system.file.getTempFile(filetype)
system.file.writeFile(path, fileBytes)
system.net.openURL("file://" + path)

When I try to open a document with this code, I have the message below.

“Windows can’t open this file. To open this file, Windows needs to know what program you want to use to open it”.

Do you have a solutions ?

Thanks

Do you have a PDF reader installed and associated with the PDF file type?