2

I've been trying to migrate the manual publish steps of a ClickOnce application from Visual Studio into MSBuild for build automation.

In doing so, I started getting failures during the build that I cannot resolve or find an answer to so I'm hoping that someone here might be able to help.

The error I am getting is related to the GenerateBootstrapper task. Here is the error:

Using "GenerateBootstrapper" task from assembly "Microsoft.Build.Tasks.v4.0, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a".
Task "GenerateBootstrapper" (TaskId:175)
  Task Parameter:ApplicationFile=SATT.Desktop.application (TaskId:175)
  Task Parameter:ApplicationName=SATT.Desktop (TaskId:175)
  Task Parameter:
      BootstrapperItems=
          .NETFramework,Version=v4.0,Profile=Client
                  Install=true
                  ProductName=Microsoft .NET Framework 4 Client Profile (x86 and x64)
                  Visible=False
          Microsoft.Windows.Installer.4.5
                  Install=true
                  ProductName=Windows Installer 4.5
                  Visible=False (TaskId:175)
  Task Parameter:Culture=* (TaskId:175)
  Task Parameter:FallbackCulture=en-US (TaskId:175)
  Task Parameter:OutputPath=\Drop4\  (TaskId:175)
  Task Parameter:VisualStudioVersion=11.0 (TaskId:175)


C:\Windows\Microsoft.NET\Framework\v4.0.30319\Microsoft.Common.targets (4486,5): error MSB3169: An error occurred generating a bootstrapper: Unable to begin updating resource for \Drop4\ \setup.exe with error 80070003 [my project name]

I have not been able to find an answer to this question anywhere so I am hoping I may get some help and or guidance.

3
  • \Drop4\ might not be correct, shouldn't that be a full path like c:\Drop4 or \\myserver\Drop4\ or a relative path like .\Drop4\ or ..\Drop4\ ?
    – stijn
    Oct 10, 2015 at 17:09
  • That's possible, but unfortunately I'm an absolute beginner. In my MSBuild command line, I set the following properties to fully qualified paths: PublishDir, PublishUrl, InstallUrl. Is there another property I need to set?
    – cmenard25
    Oct 12, 2015 at 13:51
  • I'm not familiar with ClickOnce nor publishing it so I have no idea which properties to set, sorry. However in my msbuild version the OutputPath of the GenerateBootstrapper task is indeed set to PublishDir so I'd guess that is the one. Doesn't it work? Anayway if it works in VS you can probably find out why it's ok there and not when using the commandline by inspecting the build log produced in VS, also set Tools > Options > Projects and Solutions > Build and Run > MSBuild project build output verbosity to Diagnostic
    – stijn
    Oct 12, 2015 at 14:12

1 Answer 1

0

From my experience that I run into a similar issue when I updated the target framework on the solution from 4.5 to 4.6.1. If you are in a similar situation, I recommend that you include/check old frameworks such as .NET FW 3.5, 4.0, 4.5.1, 4.5.2,.. in the Publish Prerequisites window.

I had very old vendor dlls which worked on 4.5 or lower versions only. Hope it helps.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.