With
Cont := TRttiContext.Create;
for Prop in Cont.GetType(TStrings).GetDeclaredProperties do
Memo1.Lines.Add(Prop.ToString);
Cont.Free;
I get list of all properties of TStrings except indexed properties (Strings, Values, ...).
As I can see in Get[Declared]Properties are never indexed properties. How can I get indexed proper...
I need to get a regular snapshot from a webcam in Delphi. Speed is not a problem (once a second is fine). I have tried demo code from based on stuff from http://delphi.pjh2.de but I can't get it to work. It compiles and runs OK but the callback function never fires.
I don't have a real webcam but am running instead a simulator. The ...
my application uses Bass.dll and i added it to the resource. I wanted it to be extracted before the application starts it chrash. how to void it?
...
I want to build a DLL that exports functions that return a string. This DLL should work with other programming languages!!
I have found all kind of nasty solutions/hacks to this, best one is to make my function return Pchar then call another function contained in the same DLL ( let's call it ReleaseMemory) to release the memory reserved...
Is there any simple function? I am searching something like that
Play(@data, 44000, 100 {time});
...
Hi,
i need to get Image of hidden IvideoWindow ("ActiveMovie Window"), which shows webcam preview. As far as i can tell preview isn't overlay, it doesn't have overlay features, i can use printscreen on it, but i need window to stay hidden all the time, so that won't help. Also PrintWindow() api function returns me black screen.
Program...
Do you possibly know about the existence of a free and open sourced Delphi code to export TDataSet to native XLS format? The question was previously asked here, yet I am looking for a free solution.
As observed in for example TeeChart.TeeStore.TSeriesDataXLS.SaveToStream writing a native XLS export function is not a rocket science, yet ...
There are some folder with more than 100 files on it.
But all files and folders names broken with wrong encoding names (UTF->ANSI).
"C:\...\Госдача-Лечебни корпус\вертолетка\Госдача-Лечебни корпус\Госдача-Лечебни корпус\вертолетка\Госдача-Лечебн...
Hello everybody,
I'm trying to output the value of a TByte as its corresponding hexadezimal representation in an AnsiString.
Example:
TByte is 0x4F
AnsiString: "4F" (two characters, a 4 and an F)
I know of the StringOf function, but that converts to the "mapped" character.
Is there any decent function build in or does somebody has a ...
Here are my types...
unit unitTestInterfaces;
interface
type
IFoo = interface
['{169AF568-4568-429A-A8F6-C69F4BBCC6F0}']
function TestFoo1:string;
function TestFoo:string;
end;
IBah = interface
['{C03E4E20-2D13-45E5-BBC6-9FDE12116F95}']
function TestBah:string;
function TestBah1:string;
end;
TFooBah ...
In some code I am fixing up, which makes heavy use of generics and interfaced types, I am getting error
E2134, Type '<void>' has no type info.
I believe it is because I am in the middle of a refactor where some deeply nested set of units that all use generics are out of sync, but the error is not happening in a place where I can mak...
I'm using Rave to generate reports, but it's poor at generating Word docs. My reporting needs are simple; the only thing I can't do easily within code is make a table. I'd love suggestions about how to display a [DB]Grid's contents (or underlying ClientDataSet records) within a bordered table, in Word or RTF compatible format.
Thanks, a...
Hi
With RttiContext.FindType('Classes.TStringList') I get RttiType of TStringList with no problem. But with RttiContext.FindType('MyUnit.TMyClass') I always get nil (of course MyUnit is in uses clause). Why, what is wrong?
Example:
unit MyUnit;
interface
uses
Classes;
type
TMyClass = class(TStringList)
end;
implementation...
I have a lot of memory allocations and the same number of FreeMem calls. What I didn't have though is a check before calling freemem to see if the pointer was nil, and a line after freeing to set the pointer to nil.
I tried to create a function to do this
procedure FreeMemAndNil(p: Pointer; size: Integer = -1);
begin
if p <> nil t...
Is there a easy way in Windows (using Delphi, not .NET) to convert UTC times to a local time, with daylight saving adjustments.
Data goes back 12 years, so needs to take account of changes in DST start/end dates over that time.
...
hello, I've a Tlistview with 3 columns, I need from Tcollection object as this follow
FListeDispoProduit := TListeDispoProduit.Create(TProduit);
with (FListeDispoProduit) do
begin
with TProduit(Add) do
begin
Name := 'Produit 01';
CIP := 'A001';
StockQty := 3;
end;
But when I try to put this object in...
hi
can some one show me how to hide/show tray icons of other applications/processes using my application,i want to hide the ''connected to internet''icon(those two computers that turn blue when data is sent/recieved/both) from my app
edit: i can hide system clock using this snippet taken from http://scalabium.com/faq/dct0147.htm
ShowWin...
I come from Java background, where we have data structures with interfaces that if its collection it support certain behaviour, and a set has another.
while programming in Delphi I thed to hit a brick wall when it comes in asking the reflection about the behaviour of items, its very strange.
for example this code does not compile
...
AdoTable1.Filter:=
'Date = #'+FormatDateTime('dd/mm/yyyy', Tomorrow)+ ' #' ;
Why is Date surrounded with number signs??
Is this Access -specific??
thanks in advance!
...
hi, what´s the best component or practice to check the orthographic error´s in the TEdit and TRichEdit components in a Form.
Thank´s
...