2

In our team, we use a common database server. When running the Orchard Setup, I point the connection string to an existing Orchard Database and got this error message:

Setup failed: The requested service 'Orchard.IWorkContextAccessor' has not been registered. To avoid this exception, either register a component to provide the service, check for service registration using IsRegistered(), or use the ResolveOptional() method to resolve an optional dependency.

The only way that can make setup successful for me is to point to an empty database. I attempted a workaround by doing so first, and then edit connection string in App_Data\Sites\Default\Settings.txt, but then I got the same error.

4

2 回答 2

0

我也有这个问题,还尝试复制不起作用的 settings.txt 文件。这次我复制了 App_data 目录的所有内容,它对我有用。另外,最近一次我使用的是 codeplex 的最新提交。

于 2012-08-30T23:06:33.400 回答
0

我删除了 cache.dat 并在 IIS 中重新启动了网站,这为我修复了它

于 2019-01-29T12:07:06.560 回答