RTC Forums
November 14, 2024, 08:01:57 AM
Welcome,
Guest
. Please
login
or
register
.
1 Hour
1 Day
1 Week
1 Month
Forever
Login with username, password and session length
Home
Help
Login
Register
RTC Forums
>
Subscription
>
Support
>
Re: Error when working with Android 6
Pages: [
1
]
« previous
next »
Print
Author
Topic: Re: Error when working with Android 6 (Read 5047 times)
cdhaene
RTC Expired
Posts: 13
Re: Error when working with Android 6
«
on:
August 03, 2017, 08:23:03 AM »
Sorry for the personal message.
do you mean that this line :
aClientDataset := TClientDataset(nativeUInt(Data.asFunction.Value['clientdataset']));
is not correct?
How should I pass the dataset?
« Sent to: cdhaene on: Today at 08:10:08 AM »
RTC Value objects do NOT store parameters as Variants. The "Value" property on RTC Value Objects convert data received as input parameter to the closest native RTC type, but is NOT going to work with ALL types supported by Variant, because RTC does NOT have an equivalent for every type supported by Variant on all platforms. When working with RTC Value Objects, instead of using the "Value" propety, you should always use the most appropriate RTC Type when accessing data. For example, use "asLargeInt" instead of "Variant" when working with 64-bit integers.
Also, in the future, please post any questions you have about the RTC SDK in the "RTC SDK Support" section on the Forum instead of sending me a private message, or ... send me an E-Mail. Thank you.
Logged
D.Tkalcec (RTC)
Administrator
Posts: 1881
Re: Error when working with Android 6
«
Reply #1 on:
August 03, 2017, 08:41:11 AM »
I've released an update for the RTC SDK (v8.20) now, extending the "TRtcFunctionInfo" class with a new "Local:TRtcInfo" property, which you can use to store any data and local objects (see "asPtr" and "asObj" properties on the "TRtcInfo" class) which you might need on the Client, once you get a Result from the Server.
So ... now, when preparing a remote function call (using the latest RTC SDK update), you can use this code to store a pointer to your local TClientDataSet object on the Client, so you can access it when you get a Result back from the Server ...
Data.asFunction.
Local.asPtr
['dataset']:=aClientDataSet;
... and when you get a Result from the Server, for example in the OnResult event, you can use this code to get your TClientDataSet back ...
aClientDataSet := TClientDataSet(Data.asFunction.
Local.asPtr
['dataset']);
In a nutshell, anything you only need locally on the Client, store it in the new Local property instead of storing it in remote function parameters (which are sent to the Server).
Best Regards,
Danijel Tkalcec
Logged
cdhaene
RTC Expired
Posts: 13
Re: Error when working with Android 6
«
Reply #2 on:
August 03, 2017, 09:59:20 AM »
fantastic support!
thanks
works like a charm again (and faster than before)
Logged
D.Tkalcec (RTC)
Administrator
Posts: 1881
Re: Error when working with Android 6
«
Reply #3 on:
August 03, 2017, 04:20:49 PM »
Perfect
Thank you for your feedback.
Best Regards,
Danijel Tkalcec
Logged
HelgeLange
RTC Expired
Posts: 100
Re: Error when working with Android 6
«
Reply #4 on:
August 03, 2017, 04:22:13 PM »
I like it, too... that comes handy!
Logged
Pages: [
1
]
Print
« previous
next »
Jump to:
Please select a destination:
-----------------------------
Dashboard
-----------------------------
=> General
=> 3rd-Party
=> Quick Start
-----------------------------
Subscription
-----------------------------
=> Support
Loading...