Пример #1
0
 static void Run()
 {
     // ExStart: SaveMsgAsTemplate
     ///<summary>
     /// This example shows how to save an Outlook MSG file to Outlook Template  using the MapiMessage API
     /// Available from Aspose.Email for .NET 6.4.0 onwards
     /// MapiMessage.SaveAsTemplate(Stream stream) - Saves to the specified stream as Outlook File Template(OFT format).
     /// MapiMessage.SaveAsTemplate(string fileName) - Saves to the specified file as Outlook File Template(OFT format).
     ///</summary>
     using (MapiMessage mapi = new MapiMessage("*****@*****.**", "*****@*****.**", "template subject", "Template body"))
     {
         string oftMapiFileName = "mapiToOft.msg";
         mapi.SaveAsTemplate(oftMapiFileName);
     }
     // ExEnd: SaveMsgAsTemplate
 }
 static void Run()
 {
     // ExStart: SaveMsgAsTemplate
     ///<summary>
     /// This example shows how to save an Outlook MSG file to Outlook Template  using the MapiMessage API
     /// Available from Aspose.Email for .NET 6.4.0 onwards
     /// MapiMessage.SaveAsTemplate(Stream stream) - Saves to the specified stream as Outlook File Template(OFT format).
     /// MapiMessage.SaveAsTemplate(string fileName) - Saves to the specified file as Outlook File Template(OFT format).
     ///</summary>
     using (MapiMessage mapi = new MapiMessage("*****@*****.**", "*****@*****.**", "template subject", "Template body"))
     {
         string oftMapiFileName = "mapiToOft.msg";
         mapi.SaveAsTemplate(oftMapiFileName);
     }            
     // ExEnd: SaveMsgAsTemplate
 }