Lazarus

Programming => Networking and Web Programming => Topic started by: Dzandaa on November 21, 2021, 12:18:35 pm

Title: TFPHTTPClient.SimpleGet catching exception
Post by: Dzandaa on November 21, 2021, 12:18:35 pm
Hi,
using Lazarus 2.0.12 on Windows and Linux

is it possible to catch exception of TFPHTTPClient.SimpleGet(URL , LMemoryStream);  when URL is not valid?

Or to Ping the URL before the call?

Thank you.

Title: Re: TFPHTTPClient.SimpleGet catching exception
Post by: jamie on November 22, 2021, 12:59:02 am
I dont see why not?

Use the TRY "The code" Except End;


 If you have already done this and it still pops up a screen in front of you this means most likely you are running the app under debug mode and should run it without debug for that to work..
TinyPortal © 2005-2018