3

I have created a vb.net application using Visual Studio 2013, I have published it and installed it on my work pc (windows 7) and my laptop (also windows 7) and they both work fine. I tried installing it on the pc this application is to go on which is windows xp, I got an error with the following details:

PLATFORM VERSION INFO
Windows             : 5.1.2600.196608 (Win32NT)
Common Language Runtime     : 4.0.30319.1022
System.Deployment.dll       : 4.0.30319.1 (RTMRel.030319-0100)
clr.dll             : 4.0.30319.1022 (RTMGDR.030319-1000)
dfdll.dll           : 4.0.30319.1 (RTMRel.030319-0100)
dfshim.dll          : 4.0.31106.0 (Main.031106-0000)

SOURCES
Deployment url          : file:///D:/Visitors.application

ERROR SUMMARY
Below is a summary of the errors, details of these errors are listed later in the log.
* Activation of D:\Visitors.application resulted in exception. Following failure messages were detected:
    + Exception reading manifest from file:///D:/Visitors.application: the manifest may not be valid or the file could not be opened.
    + Manifest XML signature is not valid.
    + SignatureDescription could not be created for the signature algorithm supplied.

COMPONENT STORE TRANSACTION FAILURE SUMMARY
No transaction error was detected.

WARNINGS
There were no warnings during this operation.

OPERATION PROGRESS STATUS
* [14/08/2014 13:43:54] : Activation of D:\Visitors.application has started.

ERROR DETAILS
Following errors were detected during this operation.
* [14/08/2014 13:44:00] System.Deployment.Application.InvalidDeploymentException (ManifestParse)
    - Exception reading manifest from file:///D:/Visitors.application: the manifest may not be valid or the file could not be opened.
    - Source: System.Deployment
    - Stack trace:
        at System.Deployment.Application.ManifestReader.FromDocument(String localPath, ManifestType manifestType, Uri sourceUri)
        at System.Deployment.Application.DownloadManager.DownloadDeploymentManifestDirectBypass(SubscriptionStore subStore, Uri& sourceUri, TempFile& tempFile, SubscriptionState& subState, IDownloadNotification notification, DownloadOptions options, ServerInformation& serverInformation)
        at System.Deployment.Application.DownloadManager.DownloadDeploymentManifestBypass(SubscriptionStore subStore, Uri& sourceUri, TempFile& tempFile, SubscriptionState& subState, IDownloadNotification notification, DownloadOptions options)
        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.Deployment.Application.InvalidDeploymentException (SignatureValidation)
    - Manifest XML signature is not valid.
    - Source: System.Deployment
    - Stack trace:
        at System.Deployment.Application.Manifest.AssemblyManifest.ValidateSignature(Stream s)
        at System.Deployment.Application.ManifestReader.FromDocument(String localPath, ManifestType manifestType, Uri sourceUri)
    --- Inner Exception ---
    System.Security.Cryptography.CryptographicException
    - SignatureDescription could not be created for the signature algorithm supplied.
    - Source: System.Security
    - Stack trace:
        at System.Security.Cryptography.Xml.SignedXml.CheckSignedInfo(AsymmetricAlgorithm key)
        at System.Security.Cryptography.Xml.SignedXml.CheckSignature(AsymmetricAlgorithm key)
        at System.Security.Cryptography.Xml.SignedXml.CheckSignatureReturningKey(AsymmetricAlgorithm& signingKey)
        at System.Deployment.Internal.CodeSigning.SignedCmiManifest.Verify(CmiManifestVerifyFlags verifyFlags)
        at System.Deployment.Application.Manifest.AssemblyManifest.ValidateSignature(Stream s)

COMPONENT STORE TRANSACTION DETAILS
No transaction information is available.

This is the first time I have published an application so I don't know why this is happening, I can only assume that it has something to do with windows xp. I would appreciate any help with this problem.

Update:

The .NET framework is targeted at 4.0, and the target cpu was 'Any CPU' and I changed it to x86. The xp pc in question has .NET4.0, XP SP3 and is 32-bit but this still hasn't solved my problem. Also, I am using sql server 2008r2 express in this application if that makes any difference. The old error is not coming up and the new one says: 'SqlExpress2008R2 is not a valid Win32 application.'

Update 2:

As well as having to do what I said in my first update, I also had to change the signing from 'Sign the ClickOnce manifests' to 'Sign the assembly' and my application is now working on windows xp.

Carl Onager
  • 4,112
  • 2
  • 38
  • 66
Coder92
  • 131
  • 3
  • 4
  • 14
  • This one seems related to yours: http://stackoverflow.com/questions/15782798/manifest-may-not-be-valid-or-the-file-could-not-be-opened – Kat Aug 14 '14 at 13:39
  • 1
    *How* are you installing it? via an installer, click-once, or just by copying the files? Which version of the .Net framework have you compiled for, and is that version installed on the client? Are you using a certifcate from a certificate issuer, or a self-signed certificate for publishing? – Rowland Shaw Aug 14 '14 at 13:40
  • You may need to upgrade your windows installer. "SQL Server Setup requires Microsoft Windows Installer 4.5 or a later version" From http://msdn.microsoft.com/en-us/library/ms143506(v=sql.105).aspx – Jason Hughes Aug 14 '14 at 20:04
  • @Jason Hughes, 4.5 is not available for windows xp, 4.0 is the most recent for xp. – Coder92 Aug 15 '14 at 08:11
  • Sorry, I'm wrong, I was getting it mixed up with the .NET framework where 4.0 is the most recent for windows xp. I'll try your solution @Jason Hughes. – Coder92 Aug 15 '14 at 08:19
  • 1
    Common mistake. I've had to roll out unattended installations of SQL2008 R2 to thousands of XP machines. Biggest prerequisite I needed was upgrading windows installer. It requires a reboot too so that's fun. – Jason Hughes Aug 15 '14 at 18:49

2 Answers2

0

You can can't run or build vb.net 2012/2013 or later in Windows XP.

Solution - Use vb.net 2010 in Windows XP, run and build your code there.

If any question pleasure to answer.

Ananth
  • 108
  • 6
0

The .NET framework is targeted at 4.0, and the target cpu was 'Any CPU' and I changed it to x86. The xp pc in question has .NET4.0, XP SP3 and is 32-bit. I also had to change the signing from 'Sign the ClickOnce manifests' to 'Sign the assembly' and my application is now working on windows xp.

Coder92
  • 131
  • 3
  • 4
  • 14