+ Start a Discussion
Ishan Singh 4Ishan Singh 4 

How can I access custom field on lead object from task

I am trying this   -    newTask.Lead__c.RR_ID__c == 2

newTask = new task[on task object]
RR_ID__c = custom field on lead object 

Error - Variable does not exist: newTask.Lead__c
Best Answer chosen by Ishan Singh 4
Agustin BAgustin B
Hi ishan, try this: newTask.Lead__r.RR_ID__c == 2

if it solves your issue please mark this as correct answer, it may help others.

All Answers

Agustin BAgustin B
Hi ishan, try this: newTask.Lead__r.RR_ID__c == 2

if it solves your issue please mark this as correct answer, it may help others.
This was selected as the best answer
Ishan Singh 4Ishan Singh 4
Thanks @Agustin