Server Error in '/' Application.

Object reference not set to an instance of an object.

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.NullReferenceException: Object reference not set to an instance of an object.

Source Error:


Line 71: private void LoadData() Line 72: { Line 73: grid.DataSource = SearchResult.Search(SearchText, CurrentPage, PAGE_SIZE, out pageCount); Line 74: DataBind(); Line 75: }

Source File: c:\sites\sites2010\yozma.mpage.co.il\wwwroot\Search\Default.aspx.cs    Line: 73

Stack Trace:


[NullReferenceException: Object reference not set to an instance of an object.] BLL.SearchResult.Search(String text, Int32 currentPage, Int32 pageSize, Int32& pageCount) +172 Search_Default.LoadData() in c:\sites\sites2010\yozma.mpage.co.il\wwwroot\Search\Default.aspx.cs:73 Search_Default.Page_Load(Object sender, EventArgs e) in c:\sites\sites2010\yozma.mpage.co.il\wwwroot\Search\Default.aspx.cs:66 BasePage.OnLoad(EventArgs e) +257 SitePage.OnLoad(EventArgs e) +82 System.Web.UI.Control.LoadRecursive() +70 System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +3177


Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.0.30319.17929