Getting errorr object reference not set to an instance of an

Feb 27 2013 8:17 AM
 
E_CollageBo objCollege = new E_CollageBo();
        DataTable dtCollage = objCollege.GetAllActiveCollages();
        if (dtCollage.Rows.Count > 0)
        {
            dtCollage.DefaultView.Sort = "CollegeName ASC";
            ddlCollege.DataSource = dtCollage;
            ddlCollege.TextField = "CollegeName";
            ddlCollege.ValueField = "CollegeId";
            ddlCollege.DataBind();
        }


I haven't got any sql connection to get the data to the datatable hence this dtcollage is null and is the error please let me know what i need to check

Answers (2)