I have a weird thing I want to do.
I have a server that sometimes hangs and will not accept any more input. The right fix would be to fix the offending code, but that would require a looong QA cycle which I'd like to avoid for now.
What I'd like to do is form the client end, send a packet to...
You have to call Application.ProcessMessages after you put up the splash screen in order to get the drawing to happen.
Or you could put the call to the slow routine in the splash-form's FormActivate method.
Many ways:
(1) Prefix the function name with the enclosing unit name:
A := ThisUnit.A(foo);
(2) Declare a function type variable:
type
ft = function (b:Integer) : Integer;
var
AAA: ft;
procedure ThisProcedure;
var A,b : Integer;
begin
blah
A := AAA(foo);
end...
Weird. I'm doing this in a thread and it consistently bombs out with "File being accessed by another process".
Should not happen with the csFile as a global TCriticalSection, no?
For Loops := 1 To TestLoops Do
Begin
InMemStream := TMemoryStream.Create( );
Act :=...
It's a good idea to use the Delphi TThread object to start up threads instead of the raw system API.
And you should know that the VCL is NOT THREAD SAFE.
Which means you can't willy-nilly call anything in the VCL, even a simple Add(), from a Thread. Well, you can, through the auspices of the...
I have an app that starts up just fine and starts a HTTP server on port 8181. (using delphi indy TIdHTTPServer)
All that is fine.
But sometimes the app crashes and leaves a dangling listener apparently, because when I re-run the app it says "Bind-- port already in use".
Surely there is some...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.