FIX: Cannot Add a User Programmatically by Using AuthProvider.CreateAccount (811696)



The information in this article applies to:

  • Microsoft Solution Offering - Microsoft Solution for Internet Business 2.0

SYMPTOMS

When you try to create user accounts for a solution Web site programmatically, you must call the CreateAccount method of the ContentConnector.AuthProvider class. However, you receive the following error message when you call the CreateAccount method:
Error:

Server Error in '/msib20' 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:
 Microsoft.Solutions.Framework.AccountManagementException:
 Object reference not set to an instance of an object.

Stack Trace:
 [AccountManagementException: Object reference not set to an instance of an object.]

 Microsoft.Solutions.Framework.ContentConnectorAuthProvider.CreateAccount(String userName, String password, IDictionary accountInfo)
 Microsoft.Solutions.Framework.AccountManager.CreateAccount(String userName, String password, IDictionary accountInfo)
 Microsoft.Solutions.Framework.AccountManager.CreateAccount(String userName, String password, IDictionary accountInfo)
 Microsoft.Solutions.Applications.WebForm1.btnCreate_Click(Object sender, EventArgs e) in c:\inetpub\wwwroot\msib20\regtest.aspx.cs:69
 System.Web.UI.WebControls.Button.OnClick(EventArgs e)
 System.Web.UI.WebControls.Button.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument)
 System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument)
 System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData)
 System.Web.UI.Page.ProcessRequestMain()

CAUSE

The CreateAccount method incorrectly processes the Dictionary parameters.

RESOLUTION

The CreateAccount method has been fixed to correctly process the Dictionary parameters. A supported fix is now available from Microsoft, but it is only intended to correct the problem described in this article. Only apply it to systems that are experiencing this specific problem. This fix may receive additional testing to further ensure product quality. Therefore, if you are not severely affected by this problem, Microsoft recommends that you wait for the next release that contains this hotfix.

To resolve this problem immediately, contact Microsoft Product Support Services to obtain the fix. For a complete list of Microsoft Product Support Services phone numbers and information about support costs, visit the following Microsoft Web site: Note In special cases, charges that are ordinarily incurred for support calls may be canceled if a Microsoft Support Professional determines that a specific update will resolve your problem. The usual support costs will apply to additional support questions and issues that do not qualify for the specific update in question. The English version of this fix has the file attributes (or later) that are listed in the following table. The dates and times for these files are listed in coordinated universal time (UTC). When you view the file information, it is converted to local time. To find the difference between UTC and local time, use the Time Zone tab in the Date and Time tool in Control Panel.
   Date         Time   Version    Size    File name
   -------------------------------------------------------------------------------
   17-Dec-2002  02:22  2.0.346.0  96,872  Microsoft.solutions.contentconnector.dll  

STATUS

Microsoft has confirmed that this is a bug in the Microsoft products that are listed at the beginning of this article.

Idea Section

First QFE fix release for MSIB v2.0

Modification Type:MinorLast Reviewed:10/6/2005
Keywords:kbfix KB811696 kbAudDeveloper