I'm trying to set the country field on the Address object on a Lead. However when I try to do:
mylead.address = my_country_string
It returns the error in the title of this question.
Illegal assignment from String to System.Address
If I try to do:
mylead.adddress.country = my_country_string
It returns the error
Invalid foreign key relationship: Lead.Address at line 55 column 13
How do I set the country field of the address object on a Lead if I already have a lead?