Enum FileFormat

Enum FileFormat

Nome do espaço: Aspose.Note Assembleia: Aspose.Note.dll (25.4.0)

Representa o formato de arquivo OneNote.

public enum FileFormat

Fields

OneNote2007 = 1

Apresentação do OneNote 2010.

OneNote2010 = 2

Apresentação do OneNote 2010.

OneNoteOnline = 3

OneNote em linha.

Unknown = 0

Formato de arquivo desconhecido.

Examples

Mostra como verificar se uma carga de documento está falhando porque o formato do OneNote 2007 não é suportado.

// The path to the documents directory.
                                                                                                        string dataDir = RunExamples.GetDataDir_LoadingAndSaving();
                                                                                                        string fileName = Path.Combine(dataDir, "OneNote2007.one");

                                                                                                        try
                                                                                                        {
                                                                                                            new Document(fileName);
                                                                                                        }
                                                                                                        catch (UnsupportedFileFormatException e)
                                                                                                        {
                                                                                                            if (e.FileFormat == FileFormat.OneNote2007)
                                                                                                            {
                                                                                                                Console.WriteLine("It looks like the provided file is in OneNote 2007 format that is not supported.");
                                                                                                            }
                                                                                                            else
                                                                                                                throw;
                                                                                                        }
 Português