Clickonce app file referenced wrong path to deployment codebase
I am using MSBuild to deploy my WPF app for clickonce. After deploying my application clickonce file (Myapplication.application) has the following node
<deployment install="true" mapFileExtensions="true" minimumRequiredVersion="4.9.25.0" co.v1:createDesktopShortcut="true">
<subscription>
<update>
<beforeApplicationStartup />
</update>
</subscription>
<deploymentProvider codebase="file://myapppath/myapplication.application" />
</deployment>
The base code value is taken from the csproj PublishUrl node. However, I provide this value when I publish the project using MSBuild via a command line script. Thus
<MSBuild Projects="LTL.SOL.WorkflowDesigner.csproj" Targets="Publish" Properties="PublishDir=$(PublishDir);PublishUrl=http://myapp/;InstallUrl=$(InstallUrl)"></MSBuild>
The path I supply is ignored and clickonce picks the publish url from the csproj file. Any ideas?
+3
source to share
1 answer
You can set 3 different URLs:
- PublishUrl
- UpdateUrl
- InstallUrl
It looks like you are setting the publish and set url to different values, which is normal but unusual. I would suggest setting all 3 of them to the same value and you should find that this solves your deployProvider problem. Perhaps your 'InstallUrl' property is empty and causing unwanted behavior.
+1
source to share