clickonce

Start an offline ClickOnce Application and wait for Exit

有些话、适合烂在心里 提交于 2019-12-03 14:44:53
I have deployed a ClickOnce Windows Forms application (App A) Another application (App B) starts App A with a filename as parameter. I do this with this Code var basePath = Environment.GetFolderPath(Environment.SpecialFolder.Programs); var location = String.Format(@"{0}\{1}\{2}\{3}", basePath, "MyCompany", "MyProduct", "MyApp.appref-ms"); var fileName = @"c:\temp\somefile.ext"; var uri = new Uri(fileName).ToString(); Process.Start(location, uri); App A grabs the file name from AppDomain.CurrentDomain.SetupInformation.ActivationArguments.ActivationData[0] and show the content. This works like a

Unable to apply publish properties for item X

|▌冷眼眸甩不掉的悲伤 提交于 2019-12-03 14:15:57
问题 Whenever we do a build in our main solution we receive the following warning: Unable to apply publish properties for item "microsoft.visualstudio.qualitytools.unittestframework". Has anyone seen anything like this before? Any ideas on how to fix this? It happens on all of our developer machines and also on our TFS build server as well. However, it only appears in Debug mode. 回答1: It appears that the issue is related to ClickOnce. Navigate to the project, right click on it and click on

Publish ClickOnce from the command line

耗尽温柔 提交于 2019-12-03 13:51:16
问题 Is there a way to have Visual Studio 2008 execute the "Publish Now" button from the command line? I've seen posts that suggest to use msbuild /target:publish to call it. That is OK, but MSBuild doesn't increment the revision number. I'm hoping for something like: devenv mysolution.sln /publish 回答1: To increment build numbers, I am using MSBuild Extension pack inside my .csproj file as follows: <Target Name="BeforeBuild" Condition=" '$(Configuration)|$(Platform)' == 'Release-VersionIncrement

Icon for ClickOnce application in 'Add or Remove Programs'

允我心安 提交于 2019-12-03 13:30:23
I got the icons right for my application, in the Start Menu, application folders, etc., but it doesn't come right into the Add or Remove Programs listing. What should I include for this? Sandeep You might not be able to do it directly through ClickOnce, as it's not supported. Maybe you could try editing the registry a bit as shown in Missing Icon in Add/Remove Programs for ClickOnce Application : RegistryKey myUninstallKey = Registry.CurrentUser.OpenSubKey(@"Software\Microsoft\Windows\CurrentVersion\Uninstall"); string[] mySubKeyNames = myUninstallKey.GetSubKeyNames(); for (int i = 0; i <

Problems deploying a WinForms app that uses Microsoft ReportViewer

风流意气都作罢 提交于 2019-12-03 12:47:49
I have published a WinForms application from Visual Studio 2010. It uses .NET 4.0. in the prerequisite dialog in Publish pane I selected .NET 4.0 Client Profile and Windows Installer 3.0. After publishing application to disk, I migrated it to client's computer which first installed .NET Client Profile and after reboot it gave following error message: Unable to Install or run application. The application requires that assembly, Microsoft.ReportViewer.Common version 10.0.0 in global assembly cache first. After this message the installation process exits. I'm using .NET's report in my project

A .deploy file is not deploying an XML file

给你一囗甜甜゛ 提交于 2019-12-03 12:28:26
I'm developing an application using MS Visual C# 2008 Express that uses the ClickOnce deployment functionality. I publish the application to a a server where users can download it. Upon running the application, it throws a file not found exception - it cannot find the XML file that the application pulls data from ( Instructions.xml ). When I go to the server and into the Application Files folder, I see .deploy files. One of them is for Instructions.xml.deploy . Why is Instructions.xml not being included in the user's download? Of course, if I manually copy Instructions.xml to my personal copy

Making ClickOnce Updates Mandatory?

拈花ヽ惹草 提交于 2019-12-03 12:27:22
问题 Currently in an application I'm building I have it check for updates, and it gives the user the option to install or not to install the updates. I want it to just automatically install the updates no matter what. How can I make this change? 回答1: Automatic Updates Choosing a ClickOnce Update Strategy ( Making Updates Required ) One options is to set up automatic updates to your software and mark them as required by setting the minimum required version in your deployment manifest. You can set

MSBuild cannot sign a ClickOnce manifest using a temporary key (errors MSB3326 and MSB3321)

徘徊边缘 提交于 2019-12-03 12:21:59
问题 I am trying to build a ClickOnce Windows Forms project (.NET 3.5 / Visual Studio 2010) on a Windows Server computer. (In an effort to automate the build process with Hudson CI.) For signing the ClickOnce manifest I created a temporary key in Visual Studio, temp.pfx . I can successfully build and deploy the project from Visual Studio on my workstation. But when running MSBuild on the server I get the following error messages: C:\Windows\Microsoft.NET\Framework64\v4.0.30319\Microsoft.Common

Showing ClickOnce deployment version on WPF application

不打扰是莪最后的温柔 提交于 2019-12-03 11:52:17
I'm deploying now a WPF c# project and want to put the clickonce version (rather than the assymbly or product version) on the screen title. I used to do it in Win form application with the following way. But it seems that it is not the way in WPF applications. I search on Google bu didn't find anything. Please help. if (System.Deployment.Application.ApplicationDeployment.IsNetworkDeployed) { ApplicationDeployment ad = ApplicationDeployment.CurrentDeployment; lblVer.Text = "V" + ad.CurrentVersion.ToString(); } else lblVer.Text = "V" + Application.ProductVersion.ToString(); Try this: public

Error when using Visual Studio 2010 for assembly signing: “An attempt was made to reference a token that does not exist”

不羁岁月 提交于 2019-12-03 10:57:50
I'm trying to sign an assembly in Visual Studio 2010 with our PFX file. After I enter the password for the private key, I get: An attempt was made to reference a token that does not exist How can I fix this problem? I have the same problem. Just use signtool from the Visual Studio command prompt instead. Sometimes signtool will claim your password is invalid, but usually after a couple of tries it starts working for me. signtool.exe sign /f YOURCERT.pfx /p YOURPASSWORD YOURTARGET.exe Running Visual Studio as Administrator fixed this issue for me. Beached If you want Visual Studio to