I am working on Visual Studio 2008 and ASP.net.. I want to preview email that is created in the web page. I have problems in handling double quotes in the email body.
string emailbody = "\"some text\"";
btPreviewEmail.OnClientClick = "javascript:location.href='mailto:?subject=Chalk Pushcast Software Order Agreement&body=" + emailbody + "';";
I have left the recipient’s field blank because I just have to preview the email.
At runtime, I get a Microsoft Outlook error like,
“The command line argument is not valid. Verify the switch you are using”
It looks like you need to put them on the url, so you can simply URL encode them (to
%22):