Author Topic: Repository.ImportTechnology does not work  (Read 2565 times)

stao

  • EA User
  • **
  • Posts: 137
  • Karma: +0/-0
    • View Profile
Repository.ImportTechnology does not work
« on: June 09, 2011, 12:37:38 am »
Hi,
i have a problem to use this method correctly.
iam using EA from an extern program so i cant use the OnInitializeTechnology method to inject my mdg file.

Code: [Select]
repository = new EA.Repository();
          bool val = repository.ImportTechnology(Properties.Resources.techFile);

the techfile string contains the xml data of the mdg technology.
the returnvalue is always false.
where is my mistake?

Eve

  • EA Administrator
  • EA Guru
  • *****
  • Posts: 8067
  • Karma: +118/-20
    • View Profile
Re: Repository.ImportTechnology does not work
« Reply #1 on: June 09, 2011, 08:59:57 am »
OnInitializeTechnology  is called before a model is loaded.
ImportTechnology imports the technology into the current model.

You should return your xml from OnInitializeTechnology.