Import multiples SAT files into Revit with Revit API

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hello,
I'm trying to import with the Revit API multiples SAT files that I'have created with Dynamo into Revit. Because with Revit it is possible to import a SAT file but it's only one by one. So my goal is to use Revit API to create a Ribbon Button that select a directory and import all SAT files into the active document.
I have successfuly created a Ribbon Button and i have tried to follow this topic : https://forums.autodesk.com/t5/revit-api-forum/import-sat-files-from-the-api/td-p/3902783
to import just one file but i can't get the active document and visual studio say that it is impossible to convert from Autodesk.Revit.UI.UIDocument to Autodesk.DB.Document.
Do you have any idee how can i succeed ?
I'm new with Revit API and c# sorry for the mistakes ...
Thanks,
Raphaël