RTC Forums

Subscription => Support => Topic started by: ISIGest on September 30, 2013, 11:42:49 AM



Title: Error compiling iOS Device with TRtcMemDataSet
Post by: ISIGest on September 30, 2013, 11:42:49 AM
When I try to compile a project that use TRtcMemDataSet component in iOS device I got an error:
[DCC Error] dmMain.pas(313): E2003 Undeclared identifier: 'TRtcMemDataSet'

How can I use a "asDataSet" result with iOS or Android?


Title: Re: Error compiling iOS Device with TRtcMemDataSet
Post by: D.Tkalcec (RTC) on September 30, 2013, 12:22:11 PM
TRtcMemDataSet component is not compatible with the NextGen compiler. For iOS and Android Projects, you can use the TClientDataSet component from Delphi together with the TRtcDataSetMonitor component from the RTC SDK.

To copy data from a TRtcDataSet to a TDataSet (like TClientDataSet), you can use these two procedures from the rtcDB unit:

// Copy field definition from a TRtcDataSet (used for transport ) to a Delphi TDataSet
procedure RtcDataSetFieldsToDelphi(rtcDS:TRtcDataSet; DelphiDS:TDataSet);

// Copy data rows from a TRtcDataSet (used for transport) to a Delphi TDataSet
procedure RtcDataSetRowsToDelphi(rtcDS:TRtcDataSet; DelphiDS:TDataSet);

And if you need to copy data from a TDataSet to a TRtcDataSet, you can use this procedure (usually required on the Server side):

// Copy data from a Delphi TDataSet into a TRtcDataSet (used for transport)
procedure DelphiDataSetToRtc(DelphiDS:TDataSet; rtcDS:TRtcDataSet; ClearFieldDefs:boolean=True; OnlyDataFields:boolean=True);

Best Regards,
Danijel Tkalcec


Title: Re: Error compiling iOS Device with TRtcMemDataSet
Post by: ISIGest on September 30, 2013, 01:00:01 PM
Thanks