Archive for the ‘Delphi XE2’ Category
Posted by jpluimers on 2019/08/06
Curious, but somehow shortening the library path solved the problem Alberto had: [WayBack ] Hello Everybody, I have an application developed in XE2 (Hot Fix 2 + IDE Fix Pack installed) that has started giving me the “out of memory” error message… – Alberto Paganini – Google+ :
Alberto Paganini
It turned out the length of the library path was the culprit of the IDE out of memory error messages.
I have reduced the length of the library path and the error messages have reduced dramatically.
There are still a few out of memory messages tho.
–jeroen
Posted in Delphi , Delphi XE2 , Development , Software Development | Leave a Comment »
Posted by jpluimers on 2019/02/27
There are six variations; only one can be active at a time:
Delphi Office 2000 Servers Package
Delphi Office XP Servers Package
Delphi Office 2010 Servers Package
C++Builder Office 2000 Servers Package
C++Builder Office XP Servers Package
C++Builder Office 2010 Servers Package
via: I cannot get MS Office sample automation server wrapper components. Neither of… [WayBack ]
More in depth article explaining all the nitty gritty details: There Can Only Be One! Handling Different Versions of Design Packages inside the IDE | The Art of Delphi Programming [WayBack ]
–jeroen
Posted in Delphi , Delphi 10 Seattle , Delphi 10.1 Berlin (BigBen) , Delphi 2005 , Delphi 2006 , Delphi 2007 , Delphi 2009 , Delphi 2010 , Delphi XE , Delphi XE2 , Delphi XE3 , Delphi XE4 , Delphi XE5 , Delphi XE6 , Delphi XE7 , Delphi XE8 , Development , Software Development | Leave a Comment »
Posted by jpluimers on 2018/09/04
Just found some notes from 2013 for my research list that are still relevant:
Note that if you are using Smart Pointers, use the ones that Spring4D implemented in 2015 named Shared/IShared<T>/TShared<T>, see [WayBack ] Spring4D – Pascal Today and [WayBack2 ] Smart Pointers will be in Spring4D 1.2 .
–jeroen
Posted in Delphi , Delphi 2009 , Delphi 2010 , Delphi XE , Delphi XE2 , Delphi XE3 , Delphi XE4 , Delphi XE5 , Development , Software Development | Leave a Comment »
Posted by jpluimers on 2018/07/11
When accessing the VCL from multiple threads at the same time: adopted from …\DEMOS\THREADS\THRDDEMO.DPR
Great question a while ago:
[WayBack ] “Don’t access VCL from a background thread” – how to demo that? – Primož Gabrijelčič – Google+
For me, the ultimate way why not to access the VCL from a background thread is the precursor of the official threads demo that ships from Delphi 2 to Delphi XE6 in ...DEMOS\THREADS\THRDDEMO.DPR . where you’d think the thread isolation would be in ...DEMOS\THREADS\ThSort.pas but actually is in ...DEMOS\THREADS\SortThds.pas .
The first public showing of that demo did not include main thread protection. It originates from a session at the the 1995 Borland Developers Conference where Ray Konopka showed the below code from Bob Ainsbury.
That session reminded why this joke [WayBack ] Via the EKON20 sessions… – Jeroen Wiert Pluimers – Google+ was so funny: “When Ray Konopka enters the room you have a Raize condition. “.
The question above also made me find back this reference to BorCon95 in San Diego:
Read the rest of this entry »
Posted in Delphi , Delphi 10 Seattle , Delphi 10.1 Berlin (BigBen) , Delphi 10.2 Tokyo (Godzilla) , Delphi 2 , Delphi 2005 , Delphi 2006 , Delphi 2007 , Delphi 2009 , Delphi 2010 , Delphi 3 , Delphi 4 , Delphi 5 , Delphi 6 , Delphi 7 , Delphi 8 , Delphi x64 , Delphi XE , Delphi XE2 , Delphi XE3 , Delphi XE4 , Delphi XE5 , Delphi XE6 , Delphi XE7 , Delphi XE8 , Development , Software Development | 2 Comments »
Posted by jpluimers on 2018/07/05
While updating some old code fiddling with the[WayBack ] GetThreadId function , I wanted to have some TThread wrapper around it. I had totally forgotten there has been already a means for this since Delphi 2009 (which initially had a bug , but that was worked around at first and fixed later ): [WayBack ] CurrentThread .
The latest version of Delphi, Delphi 2009, has a CurrentThread class property on the TThread class.
This will return the proper Delphi thread object if it’s a native thread. If the thread is an “alien” thread, i.e. created using some other mechanism or on a callback from a third party thread, then it will create a wrapper thread around the thread handle.
20081001 at 5:00 – [WayBack ] Barry Kelly
Sources
–jeroen
Posted in Delphi , Delphi 10 Seattle , Delphi 10.1 Berlin (BigBen) , Delphi 10.2 Tokyo (Godzilla) , Delphi 2010 , Delphi XE , Delphi XE2 , Delphi XE3 , Delphi XE4 , Delphi XE5 , Delphi XE6 , Delphi XE7 , Delphi XE8 , Development , QC , Software Development | Leave a Comment »
Posted by jpluimers on 2018/06/29
I forgot to schedule the post below. It is still relevant if you create a machine with lots of Delphi versions on it.
Read the rest of this entry »
Posted in .NET , .NET 2.0 , .NET 3.0 , .NET 3.5 , Database Development , Delphi , Delphi 2007 , Delphi XE , Delphi XE2 , Delphi XE3 , Delphi XE4 , Delphi XE5 , Development , Firebird , InterBase , Power User , Software Development , Windows , Windows 8 | 2 Comments »
Posted by jpluimers on 2018/04/24
Posted in Delphi , Delphi 10 Seattle , Delphi 2010 , Delphi XE , Delphi XE2 , Delphi XE3 , Delphi XE4 , Delphi XE5 , Delphi XE6 , Delphi XE7 , Delphi XE8 , Development , Software Development | 1 Comment »
Posted by jpluimers on 2018/04/24
Thomas Pfister came with a nice solution to this question:
[WayBack ] Does anyone know how to embed a superscript Registered symbol in a Rave memo buffer? – Phillip Woon – Google+
Since Google has such bad indexing of G+, here is the solution:
procedure TForm4.RvSystem1Print(Sender: TObject);
const
SuperscriptOn = RPTFPrefix + RPTFSuperscript + RPTFOn + RPTFSuffix; // from RpDefine.pas
SuperscriptOff = RPTFPrefix + RPTFSuperscript + RPTFOff + RPTFSuffix;
var
MemoBuf: TMemoBuf;
begin
MemoBuf := TMemoBuf.Create;
try
MemoBuf.Text := 'Test' + SuperscriptOn + '®' + SuperscriptOff + ' Test';
MemoBuf.PrintStart := 0.5;
MemoBuf.PrintEnd := 8.0;
with Sender as TBaseReport do begin
PrintMemo(MemoBuf, 1, true);
end;
finally
FreeAndNil(MemoBuf);
end;
end;
–jeroen
Source: Does anyone know how to embed a superscript Registered symbol in a Rave memo …
Posted in Delphi , Delphi 10 Seattle , Delphi 10.1 Berlin (BigBen) , Delphi 2007 , Delphi 2009 , Delphi 2010 , Delphi XE , Delphi XE2 , Delphi XE3 , Delphi XE4 , Delphi XE5 , Delphi XE6 , Delphi XE7 , Delphi XE8 , Development , Software Development | Leave a Comment »
Posted by jpluimers on 2018/04/19
I knew that methods on interfaces were not compatible with the procedure of object (like [WayBack ] TProc )or function of object construct, but they are also not compatible with the reference to procedure or reference to function construct.
Via: [WayBack ] I try to call an Interface method from TThread.Syncrhonize()…and Berlin don’t accept that… – Paul TOTH – Google+
If you want it fixed, vote for [RSP-13007] Interface methods are not assignable to anonymous method variable – Embarcadero Technologies (Thanks Stefan Glienke ).
You can work around it with an anonymous method.
This won’t work:
program Project1;
{$APPTYPE CONSOLE}
uses
SysUtils;
type
ITest = interface
['{B5AD87E8-A3DF-4B83-BE14-997C2E76A06C}']
procedure Run;
end;
TTest = class(TInterfacedObject, ITest)
procedure Run;
end;
procedure TTest.Run;
begin
Writeln('PASS')
end;
var
test: ITest; // <- change this to TTest and it compiles
proc: TProc;
begin
test := TTest.Create;
proc := procedure begin test.Run; end; // <- this compiles
proc := test.Run; // E2010 Incompatible types: 'TProc' and 'procedure, untyped pointer or untyped parameter'
proc();
Readln;
end.
–jeroen
Posted in Delphi , Delphi 10 Seattle , Delphi 10.1 Berlin (BigBen) , Delphi XE , Delphi XE2 , Delphi XE3 , Delphi XE4 , Delphi XE5 , Delphi XE6 , Delphi XE7 , Delphi XE8 , Development , Software Development | Leave a Comment »
Posted by jpluimers on 2018/04/18
Reminder to self that I one day need to write more about this enumerator:
[WayBack ] jeroenp / BeSharp.net / source / Native / Delphi / Library / Data / DataSetEnumeratorUnit.pas — Bitbucket
It’s not nearly as good as the one by Uwe Raabe, but I didn’t really update this code for about a decade as it has functioned well for me in the current state: in 2009 it was like [WayBack ] bo library – Source Code .
Code by Uwe is at [WayBack ] Dataset Enumerator Reloaded | The Art of Delphi Programming via [WayBack ] Refurbishing old code: http://www.uweraabe.de/Blog/2017/02/09/dataset-enumerator-reloaded/ – Uwe Raabe – Google+
A couple of years ago I wrote a two-part article about a dataset enumerator: A Magical Gathering – Part 1 and Part 2 . Well, things evolved a bit since then and I wondered how one would implement something similar given the current features of Delphi. Actually I am following here a suggestion from commenter Alan Clark.
So for now it’s just to document that my enumerator is there and that it works as intended.
I referenced an older version at [WayBack ] For-in Enumeration – ADUG as I used it at Spoken @ CodeRage III, December 1-5, 2008 on Delphi, database and XML related topics and Source: Conferences/2009/DelphiLive.2009/Smarter-code-with-databases-and-data-aware-controls .
A small video on how you use it is here:
VIDEO
It was back when Better Office and CodeGear still existed and we celebrated (late ) Gwan Tan’s 50th birthday.
O the days (:
More history:
–jeroen
Posted in Delphi , Delphi 10 Seattle , Delphi 10.1 Berlin (BigBen) , Delphi 2007 , Delphi 2009 , Delphi 2010 , Delphi XE , Delphi XE2 , Delphi XE3 , Delphi XE4 , Delphi XE5 , Delphi XE6 , Delphi XE7 , Delphi XE8 , Development , Software Development | 2 Comments »