Recently I had strange problem. I’ve created workflow with Visual studio 2008 which and I would like to use Workflow component: “SendEmail” for some cases. And if I enter directly into component email address for field: “TO” the message will be delivered. But if I use simple code with the same email address for field ”TO” it doesn’t work (field TO is empty now).

private void sendEmail_ExecuteCode(object sender, EventArgs e)


sendWithInformation.To = @”[email protected]” ;

sendWithInformation.Subject = “Subject” ;

sendWithInformation.Body = “Body message” ;


And I need this code as in production environment field TO will be changing. There were just entry in log file:

08/24/2010 16:02:06.99 w3wp.exe (0x021C) 0x16F8 Windows SharePoint Services General 8kh7 High Can’t finish this action . Try again.

So, what’s going on? I try different solutions and without any result. Until I get response from Ginni Sharma on my post  . It was necessary to create variable for this component which holds “TO” field. And then If I assign email address to it message will be delivered. Strange…