StrataFrame Forum

How to divide in several proyects an application?

http://forum.strataframe.net/Topic21069.aspx

By Juan Carlos Pazos - 12/8/2008

Hi

I have a proyecto with all BOs, BBSs, forms, reports, resources and all in the same proyect.

After read something about, I think that it's best have several proyects similar as StrataFlix. But I don't know how to divide it.

The idea is one Proyect for the BOs and BBSs, another for reports, another for the forms.

If someone have already do this, can you share how can I do this?

And a second thing, in my app, I put every image as a Proyect Resource File, is this right or is better use Import Local Resource. If I use Local Resource, the images should be stored also in the machine that is going to run the application?

Thanks for you valuable help.

By Greg McGuffey - 12/9/2008

Juan,



You on the right track. Multiple projects is a better way to go. During SF training they suggested:



1. Base project. It would contain any common code. Common functions, tools, anything likely needed by all others.

2. Business project. Contains Business objects and any associated code.

3. UI project. Contains any UI elements, like custom controls, user controls, base form(s).

4. Main project. The actual EXE, with forms.

5. Modular projects. Projects with more specific focus. This is were you'd have a report assembly.



That is the short version. If you have more questions, just ask!
By Trent L. Taylor - 12/9/2008

Greg is giving good advice.  It is always a good idea to split your application in sections in the manner that Greg mentioned.  Past the examples that Greg gave, another would be a Reporting project.  This would contain all of your reports and reporting related BBS and BO classes.  This is just another example to help clear things. up.  Hope it helps. Smile
By Keith Chisarik - 12/9/2008

Excellent advice and well worth the time to do, I have been much happier since I started doing this after the training session. I have it exactly like Greg and Trent laid out, I also put any "special" functionality in another assembly, for instance "Scanning" was a recent one that got its own.
By Juan Carlos Pazos - 12/9/2008

Hi

Thanks for your advise. After more than 200 errors and still dealing with the ListView and ComboBox references that are wrong and some SearchWindows, but I the end it will be a good thing.

Regards

By Edhy Rijo - 12/9/2008

Juan Carlos Pazos (12/09/2008)
... After more than 200 errors and still dealing with the ListView and ComboBox references that are wrong and some SearchWindows, but I the end it will be a good thing.

Hi Juan,

I have done this before, and there are some references which are not changed automatically by VS, specially in the designer files, so I suggest you do this one step at a time and when changing a reference, then use the Find/Replace feature to look for the all reference in hidden files and replace it with new one, this will do the trick for ListView, ComboBoxes and any type reference used by SF.

By Greg McGuffey - 12/10/2008

Only 200 errors. Tongue I think the first time I did this (yeah, I got it wrong the first time or two Crazy ), I had like 600 errors...hard to tell as I had reached max in the error window. However, setting references and imports (using in c#) took care of it moderately painlessly. I just used the errors window, double click, then either change namespace or ctl-home to add imports/using.