YAFLogo

mrbruce
  • mrbruce
  • 59% (Neutral)
  • YAF Forumling Topic Starter
16 years ago
After doing a fresh install of 1.9.3 RC2, I was able to add two new users (plus the Admin user of course). When I try to add another user (whether from Admin or from Register), I get this:

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.

When I change compilation debug to true in my web.config, I get this:

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 106: this.Controls.AddAt( 0, _header );

Line 107:

Line 108: this.Controls.Add( forumControl );

Line 109:

Line 110: // add the footer control after the page...

Source File: c:\HostingSpaces\bcirrinone\pvt.TheDutifulDaughter.com\wwwroot\App_Code\YAF\Forum.cs Line: 108

Stack Trace:

[NullReferenceException: Object reference not set to an instance of an object.]

YAF.Classes.Utils.YafContext.get_UnreadPrivate() +25

YAF.Classes.Base.ForumPage.ForumPage_Init(Object sender, EventArgs e) +486

System.Web.UI.Control.OnInit(EventArgs e) +99

System.Web.UI.UserControl.OnInit(EventArgs e) +74

System.Web.UI.Control.InitRecursive(Control namingContainer) +321

System.Web.UI.Control.AddedControl(Control control, Int32 index) +221

System.Web.UI.ControlCollection.Add(Control child) +146

YAF.Forum.Forum_Load(Object sender, EventArgs e) in c:\HostingSpaces\bcirrinone\pvt.TheDutifulDaughter.com\wwwroot\App_Code\YAF\Forum.cs:108

System.Web.UI.Control.OnLoad(EventArgs e) +99

System.Web.UI.Control.LoadRecursive() +47

System.Web.UI.Control.LoadRecursive() +131

System.Web.UI.Control.LoadRecursive() +131

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

Version Information: Microsoft .NET Framework Version:2.0.50727.1433; ASP.NET Version:2.0.50727.1433

What am I doing wrong??? When I try to re-add the user, I'm told that he already exists, even though I can't find a record anywhere. I've used SQL Management Studio to remove all traces of the new user and tried again, but obviously I'm missing an instance! I find the unsuccessfully added new user in yaf_prov_Membership, NOT in yaf_User (where I'd expect to find him); where else should I go to delete all traces so I can try again?

Sponsor
Mek
  • Mek
  • 100% (Exalted)
  • YAF Developer
16 years ago
Looks like its the Private Message bug where you don't give the private message a title. If your handy with sql just look into the private messages table and type in any Title.

We've yet to fix that one.


UserPostedImage

"It's a case of RTFM.. the only problem being we don't have a manual!"

When I post FP:Mek in a topic, I'm leaving my footprint there so I can track it once I get into coding/supporting. (Yes I stole this off Ederon 🙂 )

mrbruce
  • mrbruce
  • 59% (Neutral)
  • YAF Forumling Topic Starter
16 years ago
Ummm... but I'm not sending a PM - only trying to add a User..........

:?:

Mek
  • Mek
  • 100% (Exalted)
  • YAF Developer
16 years ago
Humour me and check. Null reference is being thrown after YAF is looking at the get_UnreadPRivate(). Unless i'm being completely stupid, which can never be ruled out.

[NullReferenceException: Object reference not set to an instance of an object.]

YAF.Classes.Utils.YafContext.get_UnreadPrivate() +25


UserPostedImage

"It's a case of RTFM.. the only problem being we don't have a manual!"

When I post FP:Mek in a topic, I'm leaving my footprint there so I can track it once I get into coding/supporting. (Yes I stole this off Ederon 🙂 )

mrbruce
  • mrbruce
  • 59% (Neutral)
  • YAF Forumling Topic Starter
16 years ago
Okay... I actually had to create a PM from within the program since there were none in the db yet. Checked it and it had a title. Deleted the person I was trying to add from the yaf_prov_Membership table and tried again to add them as New User, and received a new error:

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 102:

Line 103: // save the time zone...

Line 104: YAF.Classes.Data.DB.user_save( UserMembershipHelper.GetUserIDFromProviderUserKey( user.ProviderUserKey ), PageContext.PageBoardID, null, null, Convert.ToInt32( TimeZones.SelectedValue ), null, null, null, null, null );

Line 105:

Line 106: if ( PageContext.BoardSettings.EmailVerification )

Source File: c:\HostingSpaces\bcirrinone\pvt.TheDutifulDaughter.com\wwwroot\pages\admin\reguser.ascx.cs Line: 104

Stack Trace:

[NullReferenceException: Object reference not set to an instance of an object.]

YAF.Classes.Data.DB.user_get(Int32 boardID, Object providerUserKey) +153

YAF.Classes.Utils.UserMembershipHelper.GetUserIDFromProviderUserKey(Object providerUserKey) +43

YAF.Pages.Admin.reguser.ForumRegister_Click(Object sender, EventArgs e) in c:\HostingSpaces\bcirrinone\pvt.TheDutifulDaughter.com\wwwroot\pages\admin\reguser.ascx.cs:104

System.Web.UI.WebControls.Button.OnClick(EventArgs e) +105

System.Web.UI.WebControls.Button.RaisePostBackEvent(String eventArgument) +107

System.Web.UI.WebControls.Button.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument) +7

System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) +11

System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) +33

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

--------------------------------------------------------------------------------

Version Information: Microsoft .NET Framework Version:2.0.50727.1433; ASP.NET Version:2.0.50727.1433

What next? Oh - btw, the person IS now in the db!

EDIT: Okay - I played around and got him added in the tay_User table. I copied another ProviderUserKey for haha's and I can now see him under Members... but I can't click on his name there to do anything - it tells me:

Access Denied

You tried to enter a area where you didn't have access.

Continue...

Ideas?

ANOTHER EDIT: Okay I played some more... by clicking Search on the Filter Area of the Admin Index page, I finally see him. Trying again to edit him, I get this:

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 81: // do a quick user membership sync...

Line 82: MembershipUser user = UserMembershipHelper.GetMembershipUser( CurrentUserID );

Line 83: RoleMembershipHelper.UpdateForumUser( user, PageContext.PageBoardID );

Line 84: }

Line 85: }

Source File: c:\HostingSpaces\bcirrinone\pvt.TheDutifulDaughter.com\wwwroot\pages\admin\edituser.ascx.cs Line: 83

Stack Trace:

[NullReferenceException: Object reference not set to an instance of an object.]

YAF.Classes.Utils.RoleMembershipHelper.UpdateForumUser(MembershipUser user, Int32 pageBoardID) +30

YAF.Pages.Admin.edituser.Page_Load(Object sender, EventArgs e) in c:\HostingSpaces\bcirrinone\pvt.TheDutifulDaughter.com\wwwroot\pages\admin\edituser.ascx.cs:83

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

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

System.EventHandler.Invoke(Object sender, EventArgs e) +0

System.Web.UI.Control.OnLoad(EventArgs e) +99

System.Web.UI.Control.LoadRecursive() +47

System.Web.UI.Control.LoadRecursive() +131

System.Web.UI.Control.LoadRecursive() +131

System.Web.UI.Control.LoadRecursive() +131

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

--------------------------------------------------------------------------------

Version Information: Microsoft .NET Framework Version:2.0.50727.1433; ASP.NET Version:2.0.50727.1433

mrbruce
  • mrbruce
  • 59% (Neutral)
  • YAF Forumling Topic Starter
16 years ago
Any suggestions? I'm at a standstill here... this user cannot logon, and I still cannot create another user.

EDIT: Okay, from the Admin page, I deleted that user, then tried to add him as a New User. Now I get this error:

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 102:

Line 103: // save the time zone...

Line 104: YAF.Classes.Data.DB.user_save( UserMembershipHelper.GetUserIDFromProviderUserKey( user.ProviderUserKey ), PageContext.PageBoardID, null, null, Convert.ToInt32( TimeZones.SelectedValue ), null, null, null, null, null );

Line 105:

Line 106: if ( PageContext.BoardSettings.EmailVerification )

Source File: c:\HostingSpaces\bcirrinone\pvt.TheDutifulDaughter.com\wwwroot\pages\admin\reguser.ascx.cs Line: 104

Stack Trace:

[NullReferenceException: Object reference not set to an instance of an object.]

YAF.Classes.Data.DB.user_get(Int32 boardID, Object providerUserKey) +153

YAF.Classes.Utils.UserMembershipHelper.GetUserIDFromProviderUserKey(Object providerUserKey) +43

YAF.Pages.Admin.reguser.ForumRegister_Click(Object sender, EventArgs e) in c:\HostingSpaces\bcirrinone\pvt.TheDutifulDaughter.com\wwwroot\pages\admin\reguser.ascx.cs:104

System.Web.UI.WebControls.Button.OnClick(EventArgs e) +105

System.Web.UI.WebControls.Button.RaisePostBackEvent(String eventArgument) +107

System.Web.UI.WebControls.Button.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument) +7

System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) +11

System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) +33

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

--------------------------------------------------------------------------------

Version Information: Microsoft .NET Framework Version:2.0.50727.1433; ASP.NET Version:2.0.50727.1433

mrbruce
  • mrbruce
  • 59% (Neutral)
  • YAF Forumling Topic Starter
16 years ago
NObody has any insight to offer??????
mddubs
  • mddubs
  • 100% (Exalted)
  • YAF Developer
16 years ago
Be aware of caching. While testing, you create/delete users & forums quickly and then run into unexpected results when trying to access them because the cache hasn't caught up.

Other than that, it sounds like Mek was right about your PM with no title, but you never confirmed that was true. Maybe that is the root of all this trouble.

I've installed 1.9.3RC2 many times and in many configurations and never had any trouble creating users. I would try starting over.


UserPostedImage 

www.bunkerhollow.com  | www.careercomputing.com 

When I post fp:mddubs in a topic, I'm leaving my footprint there so I can track it once I get into coding/supporting. (Yes I stole this off Mek 🙂, who stole this off Ederon 🙂 )

Mek
  • Mek
  • 100% (Exalted)
  • YAF Developer
16 years ago
Would also be interested to know whether you have made any changes the .config files particularly relating to the Membership, Roles, and PRofiles providers.


UserPostedImage

"It's a case of RTFM.. the only problem being we don't have a manual!"

When I post FP:Mek in a topic, I'm leaving my footprint there so I can track it once I get into coding/supporting. (Yes I stole this off Ederon 🙂 )

mrbruce
  • mrbruce
  • 59% (Neutral)
  • YAF Forumling Topic Starter
16 years ago
I guess I wasn't clear enough earlier... I *DID* follow Mek's instructions - I had to add a PM, then checked, and there WAS a title.

NO changes in the config files except as regards my connection string.

With this particular installation, I only need four (4) users... and for whatever reason, I'm only able to create three. So I think the advice about reinstalling is probably good advice and I will probably attempt that tomorrow. Thanks all!

mrbruce
  • mrbruce
  • 59% (Neutral)
  • YAF Forumling Topic Starter
16 years ago
UPDATE:

Even though the holidays took their toll and postponed my reinstallation, I've finally accomplished it - and in case anybody was following this thread - it solved my problems! I've been able to create new users as needed with no further problems! Thanks to all who provided insight, and Happy New Year!

:lol: