Book a Demo

Author Topic: [Help] How To Solve this Problem!  (Read 9193 times)

czc

  • EA Novice
  • *
  • Posts: 9
  • Karma: +0/-0
    • View Profile
[Help] How To Solve this Problem!
« on: December 26, 2012, 06:47:53 pm »
My Code is like this:
              
 EA.Project eaproject = m_eafile.GetProjectInterface();
                EA.Package eapackage = (EA.Package)m_eafile.Models.GetAt(0);
                eaproject.ExportPackageXMI(eapackage.PackageGUID, EA.EnumXMIType.xmiEA11, 1, -1, 1, 0, strXmlFileName);


I see this error information:

"Retrieving the COM class factory for component with CLSID {67F4E0FA-46A7-4255-B084-69A9433D08C3} failed due to the following error: 80080005"

Eve

  • EA Administrator
  • EA Guru
  • *****
  • Posts: 8110
  • Karma: +119/-20
    • View Profile
Re: [Help] How To Solve this Problem!
« Reply #1 on: December 27, 2012, 08:28:41 am »
You haven't really provided enough information for anyone to determine the problem.

Windows is unable to find the EA Repository class.

Could be a permissions issue, EA not being installed correctly or any number of other possibilities.

czc

  • EA Novice
  • *
  • Posts: 9
  • Karma: +0/-0
    • View Profile
Re: [Help] How To Solve this Problem!
« Reply #2 on: December 27, 2012, 02:25:44 pm »
First,thanks for your reply.I just want export the xml from a eap file .There is my situations:
(1) My computer has installed EA 7.0, and this error is not everytime happend.
(2) That code running on the virtual machine.
(3) The "Interop.EA.dll" file's verison is 2.10.0.0.

BTW:
http://community.sparxsystems.com/tutorials/code-engineering/running-enterprise-architect-server
I used the approach of this page,it doesn't worked.
So,help me plz. :(

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13523
  • Karma: +574/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: [Help] How To Solve this Problem!
« Reply #3 on: December 27, 2012, 06:19:20 pm »
Not even close to giving enough information.

- Which programming language are you using
- Which operating system are you using?
- Is only the code running on a virtual machine or also EA?
- Is it only that code that fails, or does any EA related code fail?
- Have you tried something simpler using code from the examples?
- Why have you used the approach suggested on the community site?
- ..?

Geert

czc

  • EA Novice
  • *
  • Posts: 9
  • Karma: +0/-0
    • View Profile
Re: [Help] How To Solve this Problem!
« Reply #4 on: December 28, 2012, 12:41:05 pm »
- Which programming language are you using?
C#
- Which operating system are you using?
Windows XP SP3
- Is only the code running on a virtual machine or also EA?
Only running the code.
- Is it only that code that fails, or does any EA related code fail?
No,any EA realated code can be failed too.
- Have you tried something simpler using code from the examples?
Yes,same result.
- Why have you used the approach suggested on the community site?
eh,just see the same error,so ....

Thxs, ;D

Eve

  • EA Administrator
  • EA Guru
  • *****
  • Posts: 8110
  • Karma: +119/-20
    • View Profile
Re: [Help] How To Solve this Problem!
« Reply #5 on: December 28, 2012, 01:47:07 pm »
The first thing to try is to forget about running as a server until you can get the code working normally.

In a new project, follow the instructions for the C# example at http://www.sparxsystems.com/enterprise_architect_user_guide/9.3/automation/setup.html

Once you have that working you should be able to do the export by adding your code to the function in that example (r is the same type as m_eafile)

Once you have that working then you can go back to the server implementation. It's moving outside of my experience. I don't know everything that document covers but the most common points of failure doing this that I have seen are user permissions to create COM objects and has the user got a valid license for EA set up. To alleviate the second you can run EA as that user manually.