2

I am using Tchromium Browser in delphi 10. I want to download some files through my browser, but in tchromium on before download event, there is access violation error. did tchromium support jquery library or not.

for eg.

procedure TForm1.BitBtn1Click(Sender: TObject);
begin    
  Chromium1.Load('http://download.com.np/index.php?option=xkx6MYC9Plxn1kFlPjfu5IMwegPILTeROMdQgdOqPcg&file=ngpmuiWPxE5a96_d-tQgqHnOz7sOpXrVmXoI_KKMKqE');
end;

this is download link. but tchromium is not able to download the file. anything wrong done by me??

mjn
  • 36,362
  • 28
  • 176
  • 378
  • TChromium is open source so you should be able to use the debugger and locate the source line where the AV happens. Without knowing the location, it will be hard to find the crash reason. – mjn Jan 08 '16 at 11:01
  • i am just only using a button in vcl form with tchromium. it loads the download link. but while i try to download the file, there is access violation error. i have to write code for downloading or what ? but if i disable javascript there is no error, again download link did not open dialogue for download. – shishir ghimire Jan 08 '16 at 11:18
  • TChromium is not required if you know the real address of the resource (image) on the server. You could use Indy or other non-visual components to do this. I would try this instead of using a space shuttle to get a bottle of milk :) – mjn Jan 08 '16 at 11:26
  • haha :) above code is just an example . i am on a project where i need to load many links to generate reports through webbrowser. from web i have made a pdf button, jquery on that button starts download. in normal web browser i can download the file easily. but i wanted to do it with delphi. – shishir ghimire Jan 08 '16 at 11:30
  • You can do it in Delphi witout a web browser, for example with the Indy HTTP client component (TIdHTTP) which is open source and works with Delphi 5 to . Your question is still unclear, can you provide a full HTML & JavaScript example page, without a reference to that external page? – mjn Jan 08 '16 at 14:32

0 Answers0