Hi, [:)]
It is my first post.
I have a form (FORM01) with a looto kup relation to an other form (FORM02). The goal is to make a multiple selection from the FORM02 and clic on the OK button to add thoses lines to the FORM01. Logically, I was intended to use the SETSELECTIONFILTER function.
Here is the code I put on the trigger OnLookup(VAR Text : Text[1024];)Beoolean of the FORM01**:**
CLEAR(F_JobList) ;
F_JobList.SETTABLEVIEW(Job);
F_JobList.SETRECORD(Job);
F_JobList.LOOKUPMODE(TRUE);
IF F_JobList.RUNMODAL = ACTION::LookupOK THEN BEGIN
Cpt:=0;
CurrForm.SETSELECTIONFILTER(Job);
IF Job.FINDSET THEN //S
REPEAT
Cpt:=Cpt+1;
MESSAGE(’%1’,Cpt);
T_Eligible56204.INIT; // initialise the record (does not initialise primary key)
T_Eligible56204.“Qualification Code” :=Rec.Code;
T_Eligible56204.Type := T_Eligible56204.Type::Job;
T_Eligible56204.Code := Job.“No.”;
T_Eligible56204.Name := Job.Description;
T_Eligible56204.INSERT;
UNTIL Job.NEXT = 0;
END;
THE PROBLEM is that I recieve an error message when I clic on the OK button :
Copying all filters at once can only be done between records beloinging to the same table.
An idea ? [:)]
Thanks