Search found 35 matches

by Ahmed Sayed
Mon May 11, 2020 3:50 am
Forum: Technical
Topic: Use BOOST_FOREACH with maps with variations!
Replies: 1
Views: 4703

Use BOOST_FOREACH with maps with variations!

Hi all, I want to use BOOST_FOREACH with std maps but i am having a hard time doing so. I am still using RAD studio berlin 10.1 upd 2 with boost lib ver 1.39 and 1.55 installed, also i am using the classic compiler. I want to create 4 macros 1- one to iterate using the pair of map 2- one to iterate ...
by Ahmed Sayed
Mon Jan 27, 2020 3:11 am
Forum: Technical
Topic: How to save a form with VCL controls on it
Replies: 8
Views: 15945

Re: How ta save a form with VCL controls on it

I think this mechanism is buggy in RAD Studio in general because when I try to save a third party Component in say a file or table field and try to read the component back it always gives error whether the a certain TClass is not registered and I have to Register it with RegisterClass first. But whe...
by Ahmed Sayed
Thu Dec 19, 2019 1:05 pm
Forum: Technical
Topic: Red underline in Clang
Replies: 4
Views: 11852

Re: Red underline in Clang

Hi I have the same issue as well. The code completion in C++ Builder does take a lot of time to calculate the result and LSP server consumes a lot of memory just to populate the list of functions and attributes for a TForm. It is weird that Borland 5 C++ Builder Code completion was faster than later...
by Ahmed Sayed
Sat Nov 23, 2019 8:03 am
Forum: Technical
Topic: Implementing IInterface works in VCL but not in FMX
Replies: 5
Views: 15035

Re: Implementing IInterface works in VCL but not in FMX

Thanks. But is it possible to use this in my case instead of inheritance: http://docwiki.embarcadero.com/RADStudio/Rio/en/Property_Implements_Support_for_C%2B%2BBuilder But the documentation is not clear on how to use something like my interface IViewFrame as a property and how get that interface la...
by Ahmed Sayed
Fri Nov 22, 2019 5:20 am
Forum: Technical
Topic: Implementing IInterface works in VCL but not in FMX
Replies: 5
Views: 15035

Re: Implementing IInterface works in VCL but not in FMX

Thanks Remy, But when i remove "INTFOBJECT_IMPL_IUNKNOWN" macro i still get error that i can't create instance of this TFrame Class [bcc32 Error] Unit2.h(53): E2352 Cannot create instance of abstract class 'TFmxFrame' Full parser context Unit2.cpp(6): #include Unit2.h Unit2.h(52): parsing: void Test...
by Ahmed Sayed
Tue Nov 19, 2019 8:50 am
Forum: Technical
Topic: Implementing IInterface works in VCL but not in FMX
Replies: 5
Views: 15035

Implementing IInterface works in VCL but not in FMX

Hi All, I have this interface called "IViewFrame" its implementation is like this: __interface INTERFACE_UUID("{D307ACE9-FE13-4F11-BEEB-A15C908579BC}") IViewFrame : public System::IInterface { //--------------------------------------------------------------------------- protected: //Setters/Getters ...
by Ahmed Sayed
Tue Sep 24, 2019 8:14 am
Forum: Technical
Topic: Throw exeption in #pragma startup function in dll?
Replies: 0
Views: 9511

Throw exeption in #pragma startup function in dll?

Hello every one, I was wondering if it is possible to throw exceptions in a function called with #pragma startup like this: void Func() { trow Exception("Test error"); } #pragma startup Func Becuase i tried on both Win32/Win64 and it does not work. So i had to come with a workaround like this: // TV...
by Ahmed Sayed
Sun Sep 22, 2019 4:56 am
Forum: Technical
Topic: Win64 or Clang compiler crash on CBuilder Berlin 10.1 Upd 2
Replies: 0
Views: 9942

Win64 or Clang compiler crash on CBuilder Berlin 10.1 Upd 2

Hi everyone, I don't know if it is only me or others facing the same issue. But this is deriving me crazy because it crashes a lot with 2 error messages from Windows 7/10 64bit. It happens on code completion and running the app in debug mode. On code completion the cursor loads like for ever to disp...
by Ahmed Sayed
Tue Jun 18, 2019 5:52 pm
Forum: Technical
Topic: Generate Web traffic with indy TIdHTTP?
Replies: 3
Views: 13779

Re: Generate Web traffic with indy TIdHTTP?

Thanks Remy That was very informative. I already managed to create sessions with TWebBrowser like in the code below unique_ptr<TWebBrowser> WebBrowser1(new TWebBrowser(this)); WebBrowser1->AddressBar = false; WebBrowser1->MenuBar = false; WebBrowser1->RegisterAsDropTarget = false; WebBrowser1->Silen...
by Ahmed Sayed
Tue Jun 18, 2019 9:29 am
Forum: Technical
Topic: Generate Web traffic with indy TIdHTTP?
Replies: 3
Views: 13779

Generate Web traffic with indy TIdHTTP?

Hi i am trying to generate web traffic through using a bot that should use indy's TIdHTTP to simulate this process I do a normal GET request but google analytics does not show anything (I mean no traffic no sessions or current active users). But when i use TWebBrowser every thing works fine and goog...
by Ahmed Sayed
Wed Apr 17, 2019 5:39 pm
Forum: Technical
Topic: Check if an indy Http server is active by indy client issue!
Replies: 7
Views: 20498

Re: Check if an indy Http server is active by indy client is

Thanks, But how can check the status of the client connection? and how can create another port for TIdHTTPServer with keepalive enabled for that server? or do i have to place another server component for monitoring. because the idea is to monitor that specific server.
by Ahmed Sayed
Wed Apr 17, 2019 1:56 pm
Forum: Technical
Topic: Check if an indy Http server is active by indy client issue!
Replies: 7
Views: 20498

Re: Check if an indy Http server is active by indy client is

For that matter, since you are doing real-time monitoring, why drop a connection and reconnect at 500ms intervals at all? Why not just establish a connection and leave it open? You will be notified if the connection is closed, such as when the server is shut down or killed. You mean using a TIdTCPC...
by Ahmed Sayed
Mon Apr 15, 2019 1:05 pm
Forum: Technical
Topic: How to set TIdHTTPResponseInfo RawHeaders on get request?
Replies: 1
Views: 10301

How to set TIdHTTPResponseInfo RawHeaders on get request?

Hi, I finally managed to create some kind of a load balancer and failover using indy TIdHttpServer. I just have a problem for now is that i can't set the Headers from an THTTPClient object to TIdHTTPResponseInfo RawHeaders This is my code for the On GET event void __fastcall TMain::IdHTTPServer1Comm...
by Ahmed Sayed
Fri Mar 15, 2019 7:39 am
Forum: Technical
Topic: Check if an indy Http server is active by indy client issue!
Replies: 7
Views: 20498

Re: Check if an indy Http server is active by indy client is

If i changed the timeout to 100 MS sure the process will get slower and it still timeout from time to time like giving me 7 timeouts in 1 minute during monitoring 4 servers.