Error on few Administrator Links

Topics: ASP.NET 2.0, Business Logic Layer, Controls
Oct 20, 2010 at 3:39 PM

After login to the BlogEngine, in Administration section when I click Profiles, or Add entry or Users I am getting this error.

 

Ooops! An unexpected error has occurred.
This one's down to me! Please accept my apologies for this - I'll see to it that the developer responsible for this happening is given 20 lashes (but only after he or she has fixed this problem).

Error Details:
Url : http://localhost:52457/BlogEngine.NET/admin/Pages/Users.aspx

Raw Url : /BlogEngine.NET/admin/Pages/Users.aspx

Message : Exception of type 'System.Web.HttpUnhandledException' was thrown.

Source : System.Web

StackTrace : at System.Web.UI.Page.HandleError(Exception e)

at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)

at System.Web.UI.Page.ProcessRequest(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)

at System.Web.UI.Page.ProcessRequest()

at System.Web.UI.Page.ProcessRequestWithNoAssert(HttpContext context)

at System.Web.UI.Page.ProcessRequest(HttpContext context)

at ASP.admin_pages_users_aspx.ProcessRequest(HttpContext context) in c:\Windows\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files\blogengine.net\bf9c49a1\c766480a\App_Web_qw0_sghy.2.cs:line 0

at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()

at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)

TargetSite : Boolean HandleError(System.Exception)

Message : Data is Null. This method or property cannot be called on Null values.

Source : System.Data

StackTrace : at System.Data.SqlClient.SqlBuffer.get_DateTime()

at System.Data.SqlClient.SqlDataReader.GetDateTime(Int32 i)

at BlogEngine.Core.Providers.DbMembershipProvider.GetAllUsers(Int32 pageIndex, Int32 pageSize, Int32& totalRecords) in C:\Users\Administrator\Desktop\BlogEngine.NET_1.6_(source)\BlogEngine.Core\Providers\DbMembershipProvider.cs:line 576

at admin_newuser.BindGrid() in c:\Users\Administrator\Desktop\BlogEngine.NET_1.6_(source)\BlogEngine.NET\admin\Pages\Users.aspx.cs:line 94

at admin_newuser.Page_Load(Object sender, EventArgs e) in c:\Users\Administrator\Desktop\BlogEngine.NET_1.6_(source)\BlogEngine.NET\admin\Pages\Users.aspx.cs:line 34

at System.Web.Util.CalliHelper.EventArgFunctionCaller(IntPtr fp, Object o, Object t, EventArgs e)

at System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e)

at System.Web.UI.Control.OnLoad(EventArgs e)

at System.Web.UI.Control.LoadRecursive()

at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)

TargetSite : System.DateTime get_DateTime()

 

Nov 6, 2010 at 11:14 AM

Only in these three pages I am getting above error "Profiles, Add entry and Users"

I am using Sql Server 2008

Please any help will do great

Coordinator
Nov 6, 2010 at 3:20 PM

You probably missing few tables added in the latest builds. Check 1.6 to 2.0 sql script in the setup folder.

Nov 10, 2010 at 10:43 AM

Sorry for bringing this subject up again but i am having the exact same problem after scripting the MSSQLSetup1.6.0.0.sql against a SQL database, but i can't seem to find a "1.6 to 2.0 sql script" in the setup folder?.

Nov 10, 2010 at 12:18 PM

Yes even I can't able to find a "1.6 to 2.0 sql script" in the setup folder.

:(

Nov 10, 2010 at 12:26 PM

I downloaded from the sourcecode section

http://blogengine.codeplex.com/SourceControl/changeset/view/219f92ea395e#BlogEngine%2fBlogEngine.NET%2fsetup%2fSQLServer%2fMSSQLUpgradeFrom1.6To2.0.sql

But still the same problem

Ooops! An unexpected error has occurred.
This one's down to me! Please accept my apologies for this - I'll see to it that the developer responsible for this happening is given 20 lashes (but only after he or she has fixed this problem).

Error Details:
Url : http://localhost:52457/BlogEngine.NET/admin/Pages/Profiles.aspx

Raw Url : /BlogEngine.NET/admin/Pages/Profiles.aspx

Message : Exception of type 'System.Web.HttpUnhandledException' was thrown.

 

 

Nov 11, 2010 at 2:38 AM

Thank you Jezzykiss.
I agree. I tried scripting the 1.6 to 2.0 SQL script also and the problem persists.

What can we do about it?

Problem:
"Profiles, Add entry and Users" showing: "'System.Web.HttpUnhandledException'" on Sql Server 2008.

Coordinator
Nov 11, 2010 at 4:35 PM

jezzykiss:  The error message you posted in your original thread had good error details in it.  But your latest error message is only 3 lines.  Is there not more error lines?  Is it the same error you're getting now that you originally were getting?

It looks like you're using the DB for storage.  Based on the original error you had, if you look in the be_Users DB table, it may be that you have NULL values for either Username, EmailAddress or LastLoginTime.  There should not be any NULL values there.  The error message is indicating that one of these values is NULL.

Nov 15, 2010 at 3:01 PM

Yes now the problem solves.

Problem was, I am using 'Admin' login this record has no null value. I have another usename in that table and its lastlogindate was null. now I entered sa date in db and tested the site. It was working fine.