Crashing error when the Username is an email address

rated by 0 users
Not Answered This post has 0 verified answers | 1 Reply | 0 Followers

David Silverlight
Not Ranked
11 Posts
Points 105
By: David Silverlight
Posted: Fri, May 16 2008 6:50 PM

I am running into an error that really has me stumped.  I have recently integrated Community Server into a website and it consistently crashes when the UserName happens to be an email address. If the username is in the form of JohnSmith@mydomain.com, it crashes with an "object not found" error when I try to execute the code below.    When the user is signed in to the Community Server section, everything works great and I don't encounter any errors.  Any thoughts on what I am doing wrong or missing?

Dim u As CommunityServer.Components.User = New  CommunityServer.Components.User()

u = CommunityServer.Users.GetUserWithWriteableProfile(0, UserName,

True)

 

The error below is generated:

Critical Error: SiteUrls.Config

Specific Error Message:

Object reference not set to an instance of an object.

 
  • Post Points: 20 |

All Replies

Keyvan Nayyeri
Top 25 Contributor
2,114 Posts
Points 27,675
MVPs
By: Keyvan Nayyeri
Posted: Fri, May 30 2008 4:48 AM In reply to

Is there any CSContext in your integrated application when you call this code? Probably there isn't.

I know that you've brought your users from a CS 2.1 database and from your own Community Credit application and now have merged them into CS 2007.1 database. Email usernames are from your Community Credit application and don't work while normal usernames are from CS 2.1 that are working.

My recommendation is to execute this code from a webform that is integrated with CS 2007.1 to have a CSContext there. This is possible by adding your own Community Credit project to CS 2007.1 SDK solution.

One other solution can be debugging the current implementation to see how can you work around it. To do this, you can both use the CS SDK or at least send your stack trace from cs_Exceptions table here to let me (and others) find the actual reason and recommend you a solution.

 
  • Post Points: 5 |
Page 1 of 1 (2 items) | RSS
Powered by Community Server (Commercial Edition), by Telligent Systems

Copyright© 2008 Telligent Systems Inc. All rights reserved
CommunityServer.com  •  Telligent.com