There is a standard field in the Lead called Lead Status where I need to set it to 'closed' if there is account with the same company name and website. So I am checking programatically the values in the company and website fields and if there is account with the same name the one in the lead in the company or the same website I am trying to set the status of the lead to closed.
Example: lead company = A and website = B >>> account name = A and website = B >>> change lead status to closed.
or
lead company = A; lead website = B;
If(company.equals(account.name)) || (website.equals(account.website)){ lead.leadStatus = 'closed'; }
Could you please advise how to achieve that in Salesforce.