Visual Entity Designer and n-tier applications

2 posts, 0 answers
  1. Hendrik
    Hendrik avatar
    23 posts
    Member since:
    Jan 2008

    Posted 24 Mar 2010 Link to this post

    I have an n-tier web application. There's a Model class library containing the Domain Model created with the Visual Entity Designer. Then there's a Service class library responsible for direct communication with the Model (in this case Model == Repository). And there's my web application project calling the service. When my web application tries to query the database through the service I get an error:

    Message: Sys.WebForms.PageRequestManagerServerErrorException: No persistent class could be found.
    To define persistent classes use the [Persistent] attribute at the class level.
    If multiple projects are used additional references must be made in the configuration file.
    To update the required references use 'Update Config References' from the OpenAccess menu.


    When using the Visual Entity Designer you the 'Update Config References' menu option is disabled. As are most of the options from the OpenAccess menu. What references and/or App/Web.config additions have to be made in order to make my simple n-tier model to get to work?

    1. Model class library project containing the Domain Model created with the Visual Entity Designer
    2. Service class library  project referencing the Model class and calling the Domain Model methods ('GetAll', 'Save', 'Delete', etc.)
    3. Web application project referencing the Service class and using the service to query the database behind the Domain Model

    Please advise. I can't find any examples or forum topics concerning n-tier design when using the Visual Entity Designer.


    Hendrik
  2. Hendrik
    Hendrik avatar
    23 posts
    Member since:
    Jan 2008

    Posted 25 Mar 2010 Link to this post

    I got it to work!

    I had to add the connection string to the Web.config of the web application. Kinda makes sense...
  3. DevCraft banner
Back to Top