Click here to Skip to main content
15,891,704 members
Please Sign up or sign in to vote.
1.00/5 (2 votes)
See more:
I have done a simple project. I am getting error while publishing

Error is:

1. cannot publish because a project failed to build
2. The "SignFile" task failed unexpectedly.
System.ArgumentNullException: Value cannot be null.
Parameter name: path1
at System.IO.Path.Combine(String path1, String path2, String path3)
at Microsoft.Build.Tasks.Deployment.ManifestUtilities.SecurityUtilities.GetPathToTool()
at Microsoft.Build.Tasks.Deployment.ManifestUtilities.SecurityUtilities.SignPEFile(X509Certificate2 cert, Uri timestampUrl, String path, ResourceManager resources, Boolean useSha256)
at Microsoft.Build.Tasks.Deployment.ManifestUtilities.SecurityUtilities.SignFile(X509Certificate2 cert, Uri timestampUrl, String path)
at Microsoft.Build.Tasks.Deployment.ManifestUtilities.SecurityUtilities.SignFile(String certThumbprint, Uri timestampUrl, String path)
at Microsoft.Build.Tasks.SignFile.Execute()
at Microsoft.Build.BackEnd.TaskExecutionHost.Microsoft.Build.BackEnd.ITaskExecutionHost.Execute()
at Microsoft.Build.BackEnd.TaskBuilder.<executeinstantiatedtask>d__20.MoveNext()


I am getting this error

I cleaned solution then I build and rebuild application, published by clicking project - publish. Also tried publishing from menu still getting same error


Thanks in advance
Posted

Probably VS has got confused.

Do a Clean, as you have allready
Close down VS.
Open it again.
Do another Clean, then rebuild all.

Hopefully, it will have sorted itself out.
If it hasn't - then you have to start playing silly buggers and remove whole swathes of code and trying again until it works.
 
Share this answer
 
Comments
Usha Red E 7-Jul-14 2:07am    
Done all the things, Nothing helped :-(
Usha Red E 7-Jul-14 2:41am    
I created a new project just added a messagebox and published. getting same error. There is no extra code to remove
Ok, by doing this your name won't appear in setup, but if you want just to be able to publish, it will do.

1. Right click Project name (ex: wpfapplication1) and select proprieties
2. Select signing
3. Uncheck "sign the clickonce manifest" (this will make the setup run as unknown publisher)
4. Check "sign in assembly" and select new, and put name there
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900