Author Topic: Defaulting Class/Database Values  (Read 2229 times)

bmains

  • EA Novice
  • *
  • Posts: 19
  • Karma: +0/-0
  • I love YaBB 1G - SP1!
    • View Profile
Defaulting Class/Database Values
« on: November 20, 2007, 01:03:01 pm »
Hello,

I would like to default the classes added to a diagram to VB.NET and the database to SQL Server?  I can't figure out how that is done...

«Midnight»

  • EA Guru
  • *****
  • Posts: 5651
  • Karma: +0/-0
  • That nice Mister Grey
    • View Profile
Re: Defaulting Class/Database Values
« Reply #1 on: November 20, 2007, 02:49:02 pm »
This one is rather subtle, but yes you can.

You can set the default programming language via the Tools | Options | Source Code Engineering dialog. You can set the default database via the Settings | Database Datatypes dialog.

However, you might not find these settings 'take.' The problem is in how EA creates a new project. [I don't think this has yet been addressed by Sparx, so I'll explain below.]

When you create a new project, EA actually makes you a copy of a 'seed' project. EA then adds any patterns you request in the New Project dialog, but the process always starts with a copy operation. Back in the days of EA 4 you actually had to copy a seed project by hand. The end result is that your new project actually inherits various settings from the seed project, rather than your settings. In effect, this makes (otherwise) default settings act as if they were set on a per project basis.

The seed project has Java set as the default diagram language. It also has a different database than SQL Server (I cannot remember which).

So...

You need to make a backup copy of the seed project - safety is rather important here - and then edit the original. You'll find the seed project in the directory where you installed EA; its name is EABase.eap. Once you've made the necessary changes and saved the project, new projects will default to your new settings.

HTH, David
No, you can't have it!

bmains

  • EA Novice
  • *
  • Posts: 19
  • Karma: +0/-0
  • I love YaBB 1G - SP1!
    • View Profile
Re: Defaulting Class/Database Values
« Reply #2 on: November 21, 2007, 05:46:34 am »
Hello,

I opened EABase.eap, but it doesn't have any models in it.  How do I change the default database?

Thanks.

«Midnight»

  • EA Guru
  • *****
  • Posts: 5651
  • Karma: +0/-0
  • That nice Mister Grey
    • View Profile
Re: Defaulting Class/Database Values
« Reply #3 on: November 21, 2007, 05:50:22 am »
Ensure that there is something open, even if the project browser contains only a root node.

Then, from the EA main menu choose Settings | Database Datatypes. At the top of the resulting dialog, click the Product Name drop-down and choose your desired product. Once it is highlighted check the Set as Default box over to the right, and close the dialog.
No, you can't have it!