3

I am trying to deploy an application to a file server and generate an html file so users can download my app from this page. For some reason, however, the installation folder seems to go rogue when the file is downloaded from this page. The download links to the correct file (which exists) but then when the clickonce manifest runs it cant find the application file because it looks in my local downloads folder. I feel like this is a stupid oversight on my part but i cant figure it out. Any suggestions?

    PLATFORM VERSION INFO
    Windows             : 6.1.7601.65536 (Win32NT)
    Common Language Runtime     : 4.0.30319.18408
    System.Deployment.dll       : 4.0.30319.18408 built by: FX451RTMGREL
    clr.dll             : 4.0.30319.18408 built by: FX451RTMGREL
    dfdll.dll           : 4.0.30319.18408 built by: FX451RTMGREL
    dfshim.dll          : 4.0.41209.0 (Main.041209-0000)

SOURCES
    Deployment url          : file:///C:/Users/USERNAME/Downloads/DeploymentTest.application

IDENTITIES
    Deployment Identity     : DeploymentTest.application, Version=1.0.0.0, Culture=neutral, PublicKeyToken=e1db13b08bdedb27, processorArchitecture=x86

APPLICATION SUMMARY
    * Online only application.

ERROR SUMMARY
    Below is a summary of the errors, details of these errors are listed later in the log.
    * Activation of C:\Users\Z50BXH\Downloads\DeploymentTest.application resulted in exception. Following failure messages were detected:
        + Downloading file:///C:/Users/Z50BXH/Downloads/Application Files/DeploymentTest_1_0_0_0/DeploymentTest.exe.manifest did not succeed.
        + Could not find a part of the path 'C:\Users\USERNAME\Downloads\Application Files\DeploymentTest_1_0_0_0\DeploymentTest.exe.manifest'.
        + Could not find a part of the path 'C:\Users\USERNAME\Downloads\Application Files\DeploymentTest_1_0_0_0\DeploymentTest.exe.manifest'.
        + Could not find a part of the path 'C:\Users\USERNAME\Downloads\Application Files\DeploymentTest_1_0_0_0\DeploymentTest.exe.manifest'.

COMPONENT STORE TRANSACTION FAILURE SUMMARY
    No transaction error was detected.

WARNINGS
    There were no warnings during this operation.

OPERATION PROGRESS STATUS
    * [7/7/2014 1:08:50 PM] : Activation of C:\Users\Z50BXH\Downloads\DeploymentTest.application has started.
    * [7/7/2014 1:08:50 PM] : Processing of deployment manifest has successfully completed.
    * [7/7/2014 1:08:50 PM] : Installation of the application has started.

ERROR DETAILS
    Following errors were detected during this operation.
    * [7/7/2014 1:08:50 PM] System.Deployment.Application.DeploymentDownloadException (Unknown subtype)
        - Downloading file:///C:/Users/USERNAME/Downloads/Application Files/DeploymentTest_1_0_0_0/DeploymentTest.exe.manifest did not succeed.
        - Source: System.Deployment
        - Stack trace:
            at System.Deployment.Application.SystemNetDownloader.DownloadSingleFile(DownloadQueueItem next)
            at System.Deployment.Application.SystemNetDownloader.DownloadAllFiles()
            at System.Deployment.Application.FileDownloader.Download(SubscriptionState subState)
            at System.Deployment.Application.DownloadManager.DownloadManifestAsRawFile(Uri& sourceUri, String targetPath, IDownloadNotification notification, DownloadOptions options, ServerInformation& serverInformation)
            at System.Deployment.Application.DownloadManager.DownloadApplicationManifest(AssemblyManifest deploymentManifest, String targetDir, Uri deploymentUri, IDownloadNotification notification, DownloadOptions options, Uri& appSourceUri, String& appManifestPath)
            at System.Deployment.Application.DownloadManager.DownloadApplicationManifest(AssemblyManifest deploymentManifest, String targetDir, Uri deploymentUri, Uri& appSourceUri, String& appManifestPath)
            at System.Deployment.Application.ApplicationActivator.DownloadApplication(SubscriptionState subState, ActivationDescription actDesc, Int64 transactionId, TempDirectory& downloadTemp)
            at System.Deployment.Application.ApplicationActivator.InstallApplication(SubscriptionState& subState, ActivationDescription actDesc)
            at System.Deployment.Application.ApplicationActivator.PerformDeploymentActivation(Uri activationUri, Boolean isShortcut, String textualSubId, String deploymentProviderUrlFromExtension, BrowserSettings browserSettings, String& errorPageUrl)
            at System.Deployment.Application.ApplicationActivator.ActivateDeploymentWorker(Object state)
        --- Inner Exception ---
        System.Net.WebException
        - Could not find a part of the path 'C:\Users\USERNAME\Downloads\Application Files\DeploymentTest_1_0_0_0\DeploymentTest.exe.manifest'.
        - Source: System
        - Stack trace:
            at System.Net.FileWebRequest.EndGetResponse(IAsyncResult asyncResult)
            at System.Net.FileWebRequest.GetResponse()
            at System.Deployment.Application.SystemNetDownloader.DownloadSingleFile(DownloadQueueItem next)
        --- Inner Exception ---
        System.Net.WebException
        - Could not find a part of the path 'C:\Users\USERNAME\Downloads\Application Files\DeploymentTest_1_0_0_0\DeploymentTest.exe.manifest'.
        - Source: System
        - Stack trace:
            at System.Net.FileWebResponse..ctor(FileWebRequest request, Uri uri, FileAccess access, Boolean asyncHint)
            at System.Net.FileWebRequest.GetResponseCallback(Object state)
        --- Inner Exception ---
        System.IO.DirectoryNotFoundException
        - Could not find a part of the path 'C:\Users\USERNAME\Downloads\Application Files\DeploymentTest_1_0_0_0\DeploymentTest.exe.manifest'.
        - Source: mscorlib
        - Stack trace:
            at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)
            at System.IO.FileStream.Init(String path, FileMode mode, FileAccess access, Int32 rights, Boolean useRights, FileShare share, Int32 bufferSize, FileOptions options, SECURITY_ATTRIBUTES secAttrs, String msgPath, Boolean bFromProxy, Boolean useLongPath, Boolean checkHost)
            at System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize, FileOptions options, String msgPath, Boolean bFromProxy)
            at System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize, Boolean useAsync)
            at System.Net.FileWebStream..ctor(FileWebRequest request, String path, FileMode mode, FileAccess access, FileShare sharing, Int32 length, Boolean async)
            at System.Net.FileWebResponse..ctor(FileWebRequest request, Uri uri, FileAccess access, Boolean asyncHint)

COMPONENT STORE TRANSACTION DETAILS
    No transaction information is available.

I have looked at this reference Error deploying ClickOnce application - Reference in the manifest does not match the identity of the downloaded assembly but it didnt fix my issue.

Community
  • 1
  • 1
brhardwick
  • 3,065
  • 2
  • 15
  • 17
  • it looks like your deployment url is your downloads folder - is that correct? – blueberryfields Jul 07 '14 at 17:19
  • i know. thats the issue. Its not. I set it to the Publish directory but it just defaults to that. I think its a manifest problem – brhardwick Jul 07 '14 at 17:26
  • and when i say "defaults to that" i mean it defaults to the downloads directory. In the manifest it does not seem to specify the path, so it simply makes the path whatever the download directory was – brhardwick Jul 07 '14 at 17:36
  • are you publishing the app from Visual Studio? If are you publishing from visual studio, what is the publishing folder location? What is the installation Folder URL? – Phil Sattele Jul 07 '14 at 18:19
  • Well i am using a URL to a ftp site call it "\\winftp\App\Location" and then the installation directory is identical – brhardwick Jul 07 '14 at 19:36
  • 2
    those paths should work. Make sure you're using IE. When I try running a clickonce app with chrome I get errors similar to yours. – Phil Sattele Jul 07 '14 at 19:57

1 Answers1

4

The answer that worked is, as pSattele mentioned, that the link has to be through IE. The weird thing is that, while SSRS Report Builder works in the ClickOnce chrome extension, my app doesnt. Either way, it "works" now. Thank you all!

brhardwick
  • 3,065
  • 2
  • 15
  • 17
  • Or you could just provide the `setup.exe` bootstrapper as download link. It will download the neccessarry files and is compatible to all browsers, due to it's executed directly on the machine, not on/by the browser. – Stefan Over Jul 07 '14 at 20:11
  • Thats a really good point. Isnt this what the html does anyway? – brhardwick Jul 08 '14 at 11:31
  • Yes. But note: The html deployment page is only generated by Visual Studio. If you want to automate your build process, you are going to use msbuild. This however, doesn't generate the html file. You would need to create your own then. – Stefan Over Jul 08 '14 at 12:48
  • Worked when I used IE rather than Chrome – Rob Bowman Apr 24 '18 at 06:37