How can I retrieve values from my fields, descendants from TObjects
I have this definition of an object :
TRFComando = class(TOBject)
private
fID : Integer;
fINI : char;
fSTX : char;
fComando : String;
public
ID : Integer read fID write fID;
::: ans so on
Then I used
X := TRFComando.Create;
RFComando := TObjectList.Create(True);
RFComando.Add(X);
But when i try to retrieve values like this :
RFComando[0].ID
RFComando[0].Comando
Always comes Zero or empty Strings and chars.
Sounds like the properties i have created in my object was not stored in TObjectList but just the natural properties os the object itself.
What am I doing wrong ?
Thank You. Excuse bad English.
I have this definition of an object :
TRFComando = class(TOBject)
private
fID : Integer;
fINI : char;
fSTX : char;
fComando : String;
public
ID : Integer read fID write fID;
::: ans so on
Then I used
X := TRFComando.Create;
RFComando := TObjectList.Create(True);
RFComando.Add(X);
But when i try to retrieve values like this :
RFComando[0].ID
RFComando[0].Comando
Always comes Zero or empty Strings and chars.
Sounds like the properties i have created in my object was not stored in TObjectList but just the natural properties os the object itself.
What am I doing wrong ?
Thank You. Excuse bad English.