Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6918117
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T09:49:04+00:00 2026-05-27T09:49:04+00:00

I have been having intermittent trouble with data access so I’m rebuilding my project.

  • 0

I have been having intermittent trouble with data access so I’m rebuilding my project. I have a 3-tiere architecture using Linq to Entities with my App_Data folder with my database in by DATA (DL) layer. The only connection string to the data is in the Data layer (DL) web.config.

I am getting a error message in my UI in the ‘var GetFeatured’ statement that states that “The type ‘DL.RESTAURANT’ is defined in an assembly that is not referenced. You must add a reference to assembly ‘DL.” I have a reference in the UI to the Business Logic layer and the Business Logic layer has a reference to DL. What am I missing?

USER INTERFACE CODE-BEHIND

BLgetFeatured obj2 = new BLgetFeatured();
            int one = 29;
            int two = 54;
            int three = 49;
            int four = 41;

            int restID = one;
            var GetFeatured = obj2.getFeatured(restID);

   var GetFeatured = obj2.getFeatured(restID);
    litRestName.Text = GetFeatured[0].REST_NAME;
    litRestStreet.Text = GetFeatured[0].REST_STREET1;
    litRestPhone.Text = GetFeatured[0].REST_PHONE;
    litRestCity.Text = GetFeatured[0].CITY.CITY_NAME;
    litRestCuisine.Text = GetFeatured[0].CUISINE.CUISINE_NAME;
    litRestShortDesc.Text = GetFeatured[0].REST_DESC;
    restImage.ImageUrl = "~/Images/" + GetFeatured[0].REST_IMAGE;

BUSINESS LOGIC LAYER

using DL;

namespace BL
{
    public class BLgetRestaurants
    {

    public List<RESTAURANT> getRestaurants(string cuisineName, string cityName, string priceName, string ratingName)
    {
        DLgetRestaurants obj = new DLgetRestaurants();
        var restaurantList = obj.getRestaurants(cuisineName, cityName, priceName, ratingName);
        return restaurantList;
    }
  }
}

Data Layer (DL)

namespace DL 
{
  public class DLgetFeatured
  {
    FCGuide db = new FCGuide();
    public List<RESTAURANT> getFeatured(int restID)
    {
        var restList = (from RESTAURANT in db.RESTAURANTs.Include("CUISINE").Include("CITY")
                        where RESTAURANT.REST_ID == restID
                        select RESTAURANT).ToList();

        var result = (from RESTAURANT in db.RESTAURANTs.Include("CITY").Include("CUISINE")
                      where RESTAURANT.CUISINE.CUISINE_ID == RESTAURANT.CUISINE_ID
                      && RESTAURANT.CITY.CITY_ID == RESTAURANT.CITY_ID
                      orderby RESTAURANT.REST_NAME ascending
                      select RESTAURANT).ToList();

        return restList;
    }
  }
}
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-27T09:49:05+00:00Added an answer on May 27, 2026 at 9:49 am

    Add a reference to DL in your UI project. Since you are using that type in the UI project, you need a reference to it.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have been having some issues with LINQ-To-SQL around memory usage. I'm using it
I have been having a problem with using Bundler and being able to access
I have been having some trouble using RapidXML to parse a string. I receive
I have been having trouble pulling up a custom UIPickerView from the textfield's inputview
I have been having trouble with opening files with ifstream if I do: ifstream
I have been having some real trouble with this for a while. I am
I have been having intermittent issues on some servers running Archlinux / php-fpm 5.3.9
I have been having alot of trouble with this stupid struct. I don't see
I have been having a few issues using the quadrature function in python 2.7
I have been having trouble getting this plugin to attach correctly to ajax loaded

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.