ATMLUtilitiesLibrary.UTRSOfficeUtils.ProcessPowerPointDocument C# (CSharp) Метод

ProcessPowerPointDocument() приватный статический Метод

private static ProcessPowerPointDocument ( string fullFileName ) : Uri
fullFileName string
Результат System.Uri
        private static Uri ProcessPowerPointDocument( string fullFileName )
        {
            string tempFile = string.Format( "{0}\\{1}.html",
                                             Environment.GetFolderPath( Environment.SpecialFolder.InternetCache ),
                                             Guid.NewGuid() );
            CultureInfo saveCulture = Thread.CurrentThread.CurrentCulture;
            Microsoft.Office.Interop.PowerPoint.Application application = null;
            try
            {
                Thread.CurrentThread.CurrentCulture = new CultureInfo( "en-US" );
                application = new Microsoft.Office.Interop.PowerPoint.Application();
                Presentation document = application.Presentations.Open( fullFileName,
                                                                        MsoTriState.msoFalse,
                                                                        MsoTriState.msoFalse,
                                                                        MsoTriState.msoFalse );
                if (document != null)
                {
                    document.SaveAs( tempFile, //File Name
                                     PpSaveAsFileType.ppSaveAsHTML,
                                     MsoTriState.msoFalse
                        );
                }
            }
            finally
            {
                if (application != null)
                    application.Quit();
                Thread.CurrentThread.CurrentCulture = saveCulture;
            }
            return new Uri( tempFile );
        }