Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - waheedmp3

Pages: [1]
1
Hi again,

If you can access Repository.ConnectionString but not Repository.Models that must mean you get hold of an EA.App object, ie a running instance, but one which does not have an open repository.

You should check that there aren't any other EA instances running than the one you expect. Maybe you've created one in a script somewhere that's been left dangling?

/Uffe

You are right, there was many instances of EA in the background, I ran the taskkill command and started only one instance then it worked.

Thank you.

2
Hello,


That GetObj() looks suspicious to me.

The Windows API call is GetObject(), so GetObj() looks like a wrapper of some sort. Are you sure you've got that in scope in both environments?

And I know this is an is-it-plugged-in type question, but are you sure your EA 12 instance actually has a repository open?

Finally, unless this is a throwaway hack, this design won't work because there is no "the running instance" of EA. You can run as many instances of EA as you've got memory for, and you can even connect to the same repository in different instances on the same machine.


/Uffe

That was a typo mistake, I actually use "Marshal.GetActiveObject"

3
I need to access the running instance of EA from C#,
I have two machines one with EA version 10 installed and the other has version 12
The following code snippet works fine and returns the correct connection string with EA Version 10

Code: [Select]
EA.App EAApplication = (EA.App)Marshal.GetActiveObject("EA.App");
string connStr = EAApplication.Repository.ConnectionString;
Collection models = EAApplication.Repository.Models;

but with EA version 12 ConnectionString is empty and it throws an exception that a file must be open before accessing the repository members.

4
In order to install my add-in the users need administrator access on their machines to register the dll in the registry using regasm.exe
is there a way to enable users who have no admin access to use install the add-in?

5
Bugs and Issues / Code reverse engineering problem
« on: January 12, 2016, 08:11:22 pm »
When I attempt to use "Code Engineering > import source directory" it works fine if the target package is empty,
but, if the package is not empty(contains sub-packages), the reverse results into an empty diagram and no elements are created.

Kindly check this snapshot
https://drive.google.com/file/d/0B8sebNz6RzDKTGwxMGNvbXZFWUk/view

6
In need to generate diagrams out of source code programmatically (Using Interop.EA in C#),
How can that be done? I couldn't find it in the SDK Guide or anywhere else.

Pages: [1]