Hi KHrys, I have made the change in my source code to make ISO_Params a reccord instead of an Object. That makes sense to me, because it relieves me of having to create, then free, an object. However, I am having trouble handing the pointer to the isolated function. See my code below:'
I start by declaring the types you show in your example:
type
TISO_Params = record
seg_txt_rbi: String;
req_lst, rsp_lst, fli_lst, flo_lst: TStringList;
sys_err: Boolean;
sys_err_txt: String;
db_data_rqrd: String;
end;
PISO_Params = ^TISO_Params;
I then declare a local copy of the TISO_Params, and populate it with the data contained in the variables in the main thread (this is the stuff that must end up in the isolated function, via the pointer). The ARequest.Isolate() line is where the compiler shows an error "Illegal Type Conversion, TISO_Params to PISO_params"
procedure MyMainThreadProc(...);
...
var ISO_Params: TISO_Params;
...
begin
ISO_Params.seg_txt_rbi := seg_txt_rbi;
ISO_Params.req_lst := req_lst;
ISO_Params.rsp_lst := rsp_lst;
ISO_Params.fli_lst := fli_lst;
ISO_Params.flo_lst := flo_lst;
ISO_Params.sys_err := sys_err;
ISO_Params.sys_err_txt := sys_err_txt;
ISO_Params.db_data_rqrd := db_data_rqrd;
ARequest.Isolate(@GetAllDashItems_ISO, PISO_Params(ISO_Params)); // Trouble here
end;
The trouble line is:
ARequest.Isolate(@GetAllDashItems_ISO, PISO_Params(ISO_Params));
So my question is:
ARequest.Isolate(@GetAllDashItems_ISO, <what goes here?>);
Thanks in advance.