Lire les fichiers XBRL et iXBRL dans C#
Contents
[
Hide
]
Lire le fichier d’instance XBRL dans C#
Aspose.Finance prend en charge la lecture des documents XBRL. Pour cela, vous pouvez utiliser leXbrlDocument classe en passant le nom d’un fichier d’instance XBRL valide en tant que paramètre.
L’extrait de code C# suivant illustre la lecture d’un document d’instance XBRL.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
XbrlDocument document = new XbrlDocument(XbrlFilePath + @"IdScopeContextPeriodStartAfterEnd.xml"); | |
XbrlInstanceCollection xbrlInstances = document.XbrlInstances; | |
XbrlInstance xbrlInstance = xbrlInstances[0]; | |
List<Fact> facts = xbrlInstance.Facts; | |
SchemaRefCollection schemaRefs = xbrlInstance.SchemaRefs; | |
List<Context> contexts = xbrlInstance.Contexts; | |
List<Unit> units = xbrlInstance.Units; |
Lire le fichier iXBRL dans C#
Aspose.Finance prend en charge la lecture des documents d’instance iXBRL. Pour cela, le API fournit leInlineXbrlDocument classer. Le constructeur de laInlineXbrlDocumentaccepte le nom d’un fichier iXBRL valide.
L’extrait de code C# suivant illustre la lecture d’un document d’instance iXBRL.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
InlineXbrlDocument document = new InlineXbrlDocument(XbrlFilePath + @"account_1.html"); | |
List<InlineFact> inlineFacts = document.Facts; | |
List<Context> contexts = document.Contexts; | |
List<Unit> units = document.Units; |