• Post Reply Bookmark Topic Watch Topic
  • New Topic

Launch Default Mail client

 
Ed Nigma
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am trying to launch the default mail client when the user clicks a button on my gui. I need the email to come up with a subject and the body filled with data. I tried this by using the following command:

cmd /c start \"\" \"mailto:?subject=test&body=" + body + "\""

However this way I can not format my data (as the \n and \t does not work) and it does not allow anything larger than 1K. I saw that another option was possibly saving the message as an .eml file and then calling the eml file from the command line. I have no idea how to write the eml file. Can someone help me with what would be the best solution and if it is to save the message as an eml then how do you write and eml file?

Thanks for all of your help!
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!