Sparx Systems Forum

Enterprise Architect => Automation Interface, Add-Ins and Tools => Topic started by: Peter Ž on August 04, 2011, 06:12:40 pm

Title: Generate RTF Documentation
Post by: Peter Ž on August 04, 2011, 06:12:40 pm
Hi there,

I was wondering if there is a way to create RTFs from EA templates. I simply want my plugin to do what I can do in EA with a few clicks: open "Generate RTF Documentation", select an output file, select template and click generate. I'm doing it in C#, but I can learn from other languages as well.

Overall, I find the official documentation to be quite lacking when it comes to automation. Maybe I just haven't found it, but I'd really like an API method-by-method documentation.

Thanks in advance,

Peter
Title: Re: Generate RTF Documentation
Post by: shaunf on August 05, 2011, 11:26:46 pm
EA.Repository repo = new EA.RepositoryClass();
repo.OpenFile2(Path, Username, Password);
EA.Project proj = repo.GetProjectInterface();
proj.RunReport(PackageGUID, TemplateName, outputFileName);
              
Title: Re: Generate RTF Documentation
Post by: Peter Ž on August 06, 2011, 01:05:31 am
Thank you very much! This EA.Project class will probably come in handy.

Now I just need to find a way to include custom filters in templates ...