if have a slider component which gets its data in an asm block:
let arrayofobject = [{"id":0,"answer":"very poor"},{"id":1,"answer":"poor"},...];
how can i create in web core a data structure to use with: let arrayofobject=webcoreobject
if have a slider component which gets its data in an asm block:
let arrayofobject = [{"id":0,"answer":"very poor"},{"id":1,"answer":"poor"},...];
how can i create in web core a data structure to use with: let arrayofobject=webcoreobject
define a variable of type JSObject in your Delphi code section, then use that variable to fill in the array.
for others who struggle with this: this solved my problem:
var
i : integer;
aitem : tslider;
a2 : tarray;
begin
setlength(a2,6);
for i := 0 to 5 do begin
aitem := tslider.create;
aitem.id := i;
aitem.answer := 'text';
a2[i] := aItem;
end;
asm
let answerarray = a2
end;
thx