I needed to save an XML formatted file as a string which required double quotes around the attributes. The below code shows how to add double quotes to a string.
= "<customer name=\"Ben Perkins\" class=\"Customer\">
<property name=\"Id\" /><property name=\"Address\" />
<property name=\"Occupation\" />
<property name=\"Remark\" /></ customer >";
Notice the backslash which is added in front of the place I want the double quote added. This is commonly referred to as an escape character.