Websocket client



procedure Tfmain.websockDataReceived(Sender: TObject; Origin: string;
  Data: TJSObjectRecord);

begin

end;

how i can get data in string  ?

The actual data can be accessed via 

Data.jsobject

If you sent a string, try to cast this Data.jsobject to a string

i use rad sydney + webcore 1.4.1.0
when i try to 
qstr := data.jsobject.toString ;
i get error :
 [Erreur] umain.pas(1527): identifier not found "jsobject"

Can it be you still have an older version installed?


  TJSObjectRecord = record
    jsobject: TJSObject;
  end;

is defined in WEBLib.Controls.pas, so if you have a clean install of only latest sources, it should find this jsobject in the record.
webcore removed.
then reinstalled using tms subscription manager.
still get same error.

Try to uninstall from the Windows Control Panel, the installer wrapper and the installer.

i tryed again.
new project, i put a websocketclient, in datareceived :
//-----------------
procedure TForm1.WebSocketClient1DataReceived(Sender: TObject; Origin: string;
  Data: TJSObjectRecord);
  var qstr : string;
begin
  qstr := data.jsobject.toString;
end;
//-----------------

same error : [Erreur] Unit1.pas(31): identifier not found "jsobject"


Is this a clean setup of the latest version v1.4.2.0?

If so, please open WEBLib.Controls.pas from the "Core Source" folder and verify yourself the definition of the TJSObejctRecord type and that it has the .jsobject value.
rad Sydney + webcore 1.4.2.0
uninstall from Windows contral panel.
install from tms suscription manager

new project
same error : [Erreur] Unit1.pas(31): identifier not found "jsobject"

in 'core source'  i dont find the definition of TJSObejctRecord  in the WEBLib.Controls.pas
i found this

  TJSObjectRecord = record
    jsobject: TJSObject;
  end;

This declaration is the correct one and it is the one from the latest release.

but i still get error when i try to :
//-----------------
procedure TForm1.WebSocketClient1DataReceived(Sender: TObject; Origin: string;
  Data: TJSObjectRecord);
  var qstr : string;
begin
  qstr := data.jsobject.toString;
end;
//-----------------


Try


procedure TForm1.WebSocketClient1DataReceived(Sender: TObject; Origin: string;
  Data: TJSObjectRecord);
var
  jo: TJSObject;
  s: string;
begin
  jo := Data.jsobject;
  s := jo.toString;
end;

yes that work.
tks for help.