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 - Jon

Pages: [1]
That would be very useful - so here's another voice asking for it.


I suspect your problem lies elsewhere, or you may have a corrupted installation of EA (try reinstalling as a last resort).  The following code snippet works fine on my pc:

Code: [Select]

Set myrep = CreateObject("EA.Repository")
result = myrep.OpenFile("Z:\Model.EAP")
MsgBox result

At risk of stating the obvious, your model file does exist doesn't it?


Automation Interface, Add-Ins and Tools / Re: configuration for C#
« on: January 27, 2004, 08:07:39 am »
It's a while since the question was asked, but lots of people seem to be reading the question...

If you're using .net without Visual Studio, then you may want to look at SharpDevelop - referencing COM servers like EA is much easier that way.


It does work, but...  I've found empirically that you need to use the whole connection string - including the description part.  (EA seems to use "<description> --- <connection string>").  So you get something like this:
"My Model --- DBType=1;Connect=Provider=SQLOLEDB.1;Password=pass;Persist Security Info=True;User ID=fjd;Initial Catalog=EAModel;Data"

When I use the whole of this, it works ok for me.  (I'm using Build 660.)

Hope this helps!


Yes, there is - you need "RunHTMLReport".  This is described in the EA help file in Automation and Scripting/The Automation Interface/Reference/Project Interface


I've been writing a custom document generator using the automation interface, and I'm having problems getting the locations of elements in the generated diagrams.

I've generated a diagram using PutDiagramImageToFile, which is fine.  I can iterate the elements on the diagram using Diagram.DiagramObjects, and can get each element's "location" using the left, right, top and bottom attributes.

Here's where I get stuck - the left, right etc don't align with the element's visual appearance in the diagram.  I've tried getting the same information through the xml "project" interface - but get the same problem.  the element is drawn slightly offset compared to the coordinates reported.

Anyone know how I can get the actual location of the diagram elements?


Pages: [1]