function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion

Assign value to relationship lookup

Hi all,
I am getting this error for following code. Where C__FKClient__c and Owner__c are user lookup. I want to set email field value to C__FKClient__c from Owner__c

                                inc=new C__FKClient__c();
                                inc.C__FKClient__c = pendingresponse[i].wrap_input.Owner__c;
                                string clienEmail= pendingresponse[i];
                                system.debug(clienEmail); // prints email value properly...
                       = clienEmail;  // getting error for this field

How to assign email value .. ??
Sorry in above code i initialised inc variable as  inc=new incident__c();