Aspose.Email.Examples.CSharp.Email.IMAP.InsertHeaderAtSpecificLocation.Run C# (CSharp) Метод

Run() публичный статический Метод

public static Run ( ) : void
Результат void
        public static void Run()
        {
            //ExStart:InsertHeaderAtSpecificLocation
            // The path to the File directory.
            string dataDir = RunExamples.GetDataDir_IMAP();
            string loadFile = dataDir + "InsertHeaders.eml";
            MailMessage eml = MailMessage.Load(loadFile);
            eml.Headers.Insert("secret-header", "mystery1");
            eml.Save(dataDir + "Updated-MessageHeaders_out.eml");
            //ExEnd:InsertHeaderAtSpecificLocation
        }
    }
InsertHeaderAtSpecificLocation