I have a simple trigger that updates lead address filed from another custom object. When I am trying to add lead id in set variable, the following error is thrown:
argument cannot be null exception
Snippet code:
Trigger trigger_name on lead (before insert){
Set<id> setid = new set<id>();
For(lead of : trigger.new )
{
setid.add(of.id);
}
}