Chilkat HOME ASP Visual Basic VB.NET C# Visual C++ C MFC Delphi FoxPro Java Perl PHP Python Ruby SQL Server VBScript
Extract Files from MIMEExtract files from a MIME message.
#include <CkMime.h> #include <CkStringArray.h> void ChilkatSample(void) { CkMime mime; bool success; success = mime.UnlockComponent("Anything for 30-day trial."); if (success == false) { printf("Failed to unlock component\n"); return; } // Load a MIME document from a file: // (.mht and .eml files contain MIME). success = mime.LoadMimeFile("mst.mht"); if (success == false) { printf("%s\n",mime.lastErrorText()); return; } CkStringArray *sa = 0; sa = mime.ExtractPartsToFiles("c:/temp/mimeParts"); if (sa == 0 ) { printf("%s\n",mime.lastErrorText()); return; } long i; long n; n = sa->get_Count(); // Display the filepaths of the files created: for (i = 0; i <= n - 1; i++) { printf("%s\n",sa->getString(i)); } } |
Need a specific example? Send a request to support@chilkatsoft.com
© 2000-2010 Chilkat Software, Inc. All Rights Reserved.