title: Broken Publish in VB.net
body: <p><strong>I have managed to break my Project>Publish ability in a vb.net project. I wanted to include some files with the installer and tried doing this using Project>Properties>Resources>Files and Add Resource. That failed so I went back there and removed the resources. I can publish the project but when I try to run the setup.exe it gives a 'contact the vendor error' and looking at the log has an error like below. I'm stuck.</strong></p>
  
  <p>ERROR SUMMARY
      Below is a summary of the errors, details of these errors are listed later in the log.
      * An exception occurred while determining trust. Following failure messages were detected:
          + Value does not fall within the expected range.</p>
  
  <ul>
  <li>Activation of C:\Documents and Settings\Bob&amp;Sue\My Documents\Visual Studio 2010\Projects\Spiffy\Spiffy\publish\Spiffy.application resulted in exception. Following failure messages were detected:
      + Value does not fall within the expected range.</li>
  </ul>
  
  <p><strong>I created a new project (Junk28APR12) which just has Form1 and Label1 (with text 'Hello World!') and that will publish but again I can't successfully run the setup.exe. Here is the full error log from that:</strong></p>
  
  <p>PLATFORM VERSION INFO
      Windows             : 5.1.2600.196608 (Win32NT)
      Common Language Runtime     : 4.0.30319.239
      System.Deployment.dll       : 4.0.30319.1 (RTMRel.030319-0100)
      clr.dll             : 4.0.30319.239 (RTMGDR.030319-2300)
      dfdll.dll           : 4.0.30319.1 (RTMRel.030319-0100)
      dfshim.dll          : 4.0.31106.0 (Main.031106-0000)</p>
  
  <p>SOURCES
      Deployment url          : file:///C:/Documents%20and%20Settings/Bob&amp;Sue/My%20Documents/Visual%20Studio%202010/Projects/Junk28APR12/Junk28APR12/publish/Junk28APR12.application
      Application url         : file:///C:/Documents%20and%20Settings/Bob&amp;Sue/My%20Documents/Visual%20Studio%202010/Projects/Junk28APR12/Junk28APR12/publish/Application%20Files/Junk28APR12_1_0_0_0/Junk28APR12.exe.manifest</p>
  
  <p>IDENTITIES
      Deployment Identity     : Junk28APR12.application, Version=1.0.0.0, Culture=neutral, PublicKeyToken=18093298bace470a, processorArchitecture=x86
      Application Identity        : Junk28APR12.exe, Version=1.0.0.0, Culture=neutral, PublicKeyToken=18093298bace470a, processorArchitecture=x86, type=win32</p>
  
  <p>APPLICATION SUMMARY
      * Installable application.</p>
  
  <p>ERROR SUMMARY
      Below is a summary of the errors, details of these errors are listed later in the log.
      * An exception occurred while determining trust. Following failure messages were detected:
          + Value does not fall within the expected range.
      * Activation of C:\Documents and Settings\Bob&amp;Sue\My Documents\Visual Studio 2010\Projects\Junk28APR12\Junk28APR12\publish\Junk28APR12.application resulted in exception. Following failure messages were detected:
          + Value does not fall within the expected range.</p>
  
  <p>COMPONENT STORE TRANSACTION FAILURE SUMMARY
      No transaction error was detected.</p>
  
  <p>WARNINGS
      There were no warnings during this operation.</p>
  
  <p>OPERATION PROGRESS STATUS
      * [28/04/2012 11:12:14] : Activation of C:\Documents and Settings\Bob&amp;Sue\My Documents\Visual Studio 2010\Projects\Junk28APR12\Junk28APR12\publish\Junk28APR12.application has started.
      * [28/04/2012 11:12:14] : Processing of deployment manifest has successfully completed.
      * [28/04/2012 11:12:14] : Installation of the application has started.
      * [28/04/2012 11:12:14] : Processing of application manifest has successfully completed.
      * [28/04/2012 11:12:15] : Found compatible runtime version 4.0.30319.</p>
  
  <p>ERROR DETAILS
      Following errors were detected during this operation.
      * [28/04/2012 11:12:15] System.ArgumentException
          - Value does not fall within the expected range.
          - Source: mscorlib
          - Stack trace:
              at System.Deployment.Internal.Isolation.IDefinitionAppId.EnumAppPath()
              at System.ActivationContext.CreateFromNameAndManifests(ApplicationIdentity applicationIdentity, String[] manifestPaths)
              at System.Deployment.Application.ActivationDescription.ToActivationContext()
              at System.Deployment.Application.ApplicationActivator.DownloadApplication(SubscriptionState subState, ActivationDescription actDesc, Int64 transactionId, TempDirectory&amp; downloadTemp)
              at System.Deployment.Application.ApplicationActivator.InstallApplication(SubscriptionState&amp; subState, ActivationDescription actDesc)
              at System.Deployment.Application.ApplicationActivator.PerformDeploymentActivation(Uri activationUri, Boolean isShortcut, String textualSubId, String deploymentProviderUrlFromExtension, BrowserSettings browserSettings, String&amp; errorPageUrl)
              at System.Deployment.Application.ApplicationActivator.ActivateDeploymentWorker(Object state)
      * [28/04/2012 11:12:15] System.ArgumentException
          - Value does not fall within the expected range.
          - Source: mscorlib
          - Stack trace:
              at System.Deployment.Internal.Isolation.IDefinitionAppId.EnumAppPath()
              at System.ActivationContext.CreateFromNameAndManifests(ApplicationIdentity applicationIdentity, String[] manifestPaths)
              at System.Deployment.Application.ActivationDescription.ToActivationContext()
              at System.Deployment.Application.ApplicationActivator.DownloadApplication(SubscriptionState subState, ActivationDescription actDesc, Int64 transactionId, TempDirectory&amp; downloadTemp)
              at System.Deployment.Application.ApplicationActivator.InstallApplication(SubscriptionState&amp; subState, ActivationDescription actDesc)
              at System.Deployment.Application.ApplicationActivator.PerformDeploymentActivation(Uri activationUri, Boolean isShortcut, String textualSubId, String deploymentProviderUrlFromExtension, BrowserSettings browserSettings, String&amp; errorPageUrl)
              at System.Deployment.Application.ApplicationActivator.ActivateDeploymentWorker(Object state)</p>
  
  <p>COMPONENT STORE TRANSACTION DETAILS
      No transaction information is available.</p>