RTC Forums

Subscription => Support => Topic started by: JeffW on June 27, 2017, 11:24:52 AM



Title: getting request data using TRtcDataServer(Sender).Read
Post by: JeffW on June 27, 2017, 11:24:52 AM
Basic question here. I want to use the request data received from a Read (receiving a JSON string) but cannot find anything documenting how to parse it into an object. Response is easy, using
TRtcRecord, so looks like a good approach. How can I get received data into a TRtcRecord? or is there a better alternative?

Apologies for the newbie question.


Title: Re: getting request data using TRtcDataServer(Sender).Read
Post by: D.Tkalcec (RTC) on June 27, 2017, 12:26:10 PM
var data:TRtcValue;
begin
If Sender.Request.Complete then
  begin
  data:=TRtcValue.FromJSON(Sender.Read);
  ...