Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Open a PDF file in a new window
#3
Hi Kudzu,

Thanks for your reply. I'll see what I can find out. I know there's a demo about custom content handlers. I'll check it out.

In the meantime I have tried to get Filecopy to work, and I admit it does try, but constantly fail, mostly due to be unable to write/create the copied file, but sometimes wit a message like:
"Copy failed. The file could not be created. The path was not found." But which path ? The Fromfile or the Tofile ?

I'v tried all kind of combinations of From and To file names, but no luck so far:

var FileFrom, FileTo : string;
begin
  Filefrom := '\\file\share\100\12087.pdf';
  FileTo := 'files\12087.pdf';   (Files exists under wwwroot which is under Debug where the exefile is.
  FileCopy(FileFrom, FileTo, true);

As FileFrom is on a separate server, I have also tried mapping a drive to the share (u: \\file\share) and so setting FileFrom := 'U:\100\12087.pdf',
Even if FileFrom is from the same disk (C:\preload\12087.pdf) it's not working.

Errors is a mix of failed due to not getting the file, and not being able to create it. It might just be I have not managed to hit the right combination yet...

Regards
Soren
Reply


Messages In This Thread
Open a PDF file in a new window - by SorenJensen - 10-10-2019, 09:18 PM
RE: Open a PDF file in a new window - by kudzu - 10-11-2019, 03:41 PM
RE: Open a PDF file in a new window - by SorenJensen - 10-11-2019, 04:14 PM
RE: Open a PDF file in a new window - by kudzu - 10-11-2019, 05:03 PM

Forum Jump:


Users browsing this thread: 1 Guest(s)