ClickOnce Deployment Just Doesn't Work

İsa Sayın 5 Reputation points
2024-06-22T18:41:43.1366667+00:00

ClickOnce publisher just does not work in any kind of folder publication of a class library project or ClickOnce publishing of a Windows desktop application.

  1. In a desktop app publish; It gives could not find a part of the path error. Because app.publish folder does not exists and it does not creates it either. As shown in error screenshot the path is 103 chars long.
  2. When i manually create app.publish folder it says publish succeeded but nothing published. Then i copied built app files to app.publish folder, again nothing happens.
  3. In a class library publish to a folder, again it says publish succeeded but nothing in the publish folder. Even the folder does not exists.

I tried so many things. Deleted publish profile and created another. Created a new solution make test projects for publishing, Re-created my solution and added existing projects to it. Re-installed visual studio. Changed publishing and building configurations. Moving solution directory to root. Nothing worked for me.

I'am using Visual Studio 17.10.3 and can't publish anything. ClickOnce publish was working for me in the earlier versions of Visual Studio. (Can't remember exact version number but maybe 3 months earlier.)

Please help.

Ekran görüntüsü 2024-06-22 204939

.NET
.NET
Microsoft Technologies based on the .NET software framework.
4,103 questions
Windows 11
Windows 11
A Microsoft operating system designed for productivity, creativity, and ease of use.
10,733 questions
{count} vote

2 answers

Sort by: Most helpful
  1. Will Bodron 0 Reputation points
    2025-02-07T21:40:45.97+00:00

    https://learn.microsoft.com/en-us/visualstudio/deployment/building-dotnet-clickonce-applications-from-the-command-line?view=vs-2022

    Weirdly following these instructions on a machine with 17.12.4 got my app.publish/Application Files/ to appear.

    0 comments No comments

  2. EdwinL 0 Reputation points
    2025-02-10T14:51:30.7966667+00:00

    I had the same problem. But then I copied the project to another directory so that the files to be published ended up in a subdirectory with fewer characters. That did the trick for me. So much less then 103 characters.... unfortunately ...

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.