I have a bit of a unique situation. I have to manage a large number of nopcommerce stores, all with the same unique set of customizations. We continue to develope this product, so the solution was to alter the connection string and caching to run many nopcommerce stores on a single set of source code. Simply put, we alter the connection string based on the domain that references the stores.

We got this structure running just fine with v 1.4, however we are trying to do the same with version v 1.8. However we running into some major problems and I would love some input from any to help us get through it.

In the application's current state, it does detect the domain change and correctly loads the store's setting based on which domain is entered. However after the store loads, any link you click on error the code out. I will post the stack trace of the error at the end of this post.

We have narrowed the error down to a problem with the static SEOHelper class. We tried removing the static and replacing its references with its object. But its used in more than 900 places where it gives a the compile error.

However we are concerned because its only a part of the complete singleton pattern and more errors will come up after we resolve this.

Any help on this would be huge, we are under a hard deadline.

Thanks, Ryan

System.Web.HttpUnhandledException (0x80004005): Exception of type 'System.Web.HttpUnhandledException' was thrown. ---> System.ArgumentException: An item with the same key has already been added.     at System.Collections.Generic.Dictionary`2.Insert(TKey key, TValue value, Boolean add)     at NopSolutions.NopCommerce.BusinessLogic.SEO.SEOHelper.InitializeSeoCharacterTable() in E:\17 Nov MyCart New\NopCommerce\Libraries\Nop.BusinessLogic\SEO\SEOHelper.cs:line 90     at NopSolutions.NopCommerce.BusinessLogic.SEO.SEOHelper.GetSEName(String name) in E:\17 Nov MyCart New\NopCommerce\Libraries\Nop.BusinessLogic\SEO\SEOHelper.cs:line 1160     at NopSolutions.NopCommerce.BusinessLogic.SEO.SEOHelper.GetManufacturerUrl(Manufacturer manufacturer) in E:\17 Nov MyCart New\NopCommerce\Libraries\Nop.BusinessLogic\SEO\SEOHelper.cs:line 1368     at NopSolutions.NopCommerce.Web.Modules.ManufacturerNavigation.rptrManufacturers_ItemDataBound(Object sender, RepeaterItemEventArgs e) in E:\17 Nov MyCart New\NopCommerce\NopCommerceStore\Modules\ManufacturerNavigation.ascx.cs:line 61     at System.Web.UI.WebControls.Repeater.CreateItem(Int32 itemIndex, ListItemType itemType, Boolean dataBind, Object dataItem)     at System.Web.UI.WebControls.Repeater.CreateControlHierarchy(Boolean useDataSource)     at System.Web.UI.WebControls.Repeater.OnDataBinding(EventArgs e)     at System.Web.Util.CalliHelper.EventArgFunctionCaller(IntPtr fp, Object o, Object t, EventArgs e)     at System.Web.UI.Control.LoadRecursive()     at System.Web.UI.Control.LoadRecursive()     at System.Web.UI.Control.LoadRecursive()     at System.Web.UI.Control.LoadRecursive()     at System.Web.UI.Control.LoadRecursive()     at System.Web.UI.Control.LoadRecursive()     at System.Web.UI.Control.LoadRecursive()     at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)     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.ProcessRequest(HttpContext context)     at ASP.login_aspx.ProcessRequest(HttpContext context) in c:\Windows\Microsoft.NET\Framework64\v4.0.30319\Temporary ASP.NET Files\root\24bc616d\f0124c92\App_Web_51ri4snp.19.cs:line 0     at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()     at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)