How can I fix Error "Identifier Expected"

give a try at following:
grafik

YourMailVar.Sender = new MailAddress("Firstname.Lastname@dyckerhoff.com","Lastname Firstname")

As the DataType of Sender Property is of MailAdress we cannot assign a string due different datatype

1 Like