Pergunta

Error occurred in deployment step 'Add Solution': The default web application could not be determined. Set the SiteUrl property in feature xxx to the URL of the desired site and retry activation.Parameter name: properties.

I know you can set this manually in feature properties to a predefined url. But we have lots of different environments with different urls? Any ideas on how to solve this?

This is only a problem/required for Visual Studio deploys on certian developer environments, but if one developer sets an url manually it will fail for other environments as well.

Foi útil?

Solução

Ensure that you have a Web Application at port 80 or 443 with a site collection at the root.

This is needed for the BCS ImportModelReceiver feature receiver to work properly. This receiver is located in the Microsoft.Office.SharePoint.ClientExtensions.dll (Microsoft.Office.SharePoint.ClientExtensions.Deployment.ImportModelReceiver). You can see the code that checks for the Web Application in the GetDefaultWebAppUrl method.

Hope this helps.

J.O.

Outras dicas

Do you mean the SiteUrl defined for the project? You can try setting this to http://localhost/.

Licenciado em: CC-BY-SA com atribuição
Não afiliado a sharepoint.stackexchange
scroll top