Sparx Systems Forum

Enterprise Architect => Automation Interface, Add-Ins and Tools => Topic started by: mcavigelli on January 03, 2005, 04:09:00 am

Title: Programmtically generate code from elements
Post by: mcavigelli on January 03, 2005, 04:09:00 am
Hi,

I would like to generate the code for a class / interface programmatically (Ctrl + G in the User Interface). However I cannot find the method in the automation interface. I can only see GenerateXSD, ExportPackageXMI.

I'm using EA 3.60.

Thanks, Matthias
Title: Re: Programmtically generate code from elements
Post by: charge on January 04, 2005, 08:33:04 am
Why don't you use 4.50  ???
Title: Re: Programmtically generate code from elements
Post by: mcavigelli on January 04, 2005, 08:52:47 am
Quote
Why don't you use 4.50  ?

I work in an organisation and cannot just change it on my own. Anyway: How would it be done in 4.50? I need to bring forward arguments for upgrading...
Title: Re: Programmtically generate code from elements
Post by: thomaskilian on January 04, 2005, 12:06:16 pm
Package has a hidden method GenerateSourceCode
Title: Re: Programmtically generate code from elements
Post by: mcavigelli on January 05, 2005, 03:32:46 am
Quote
Package has a hidden method GenerateSourceCode

So does that mean that I cannot access code generation programmatically?
What's the reason for that?
Title: Re: Programmtically generate code from elements
Post by: thomaskilian on January 05, 2005, 01:57:36 pm
No idea. I found this option accidentially. Never knew before that you can hide elements in the object repository. Just give it a try and call the method...