clickonce

deploying a database and application with ClickOnce

笑着哭i 提交于 2019-11-28 22:04:53
I am new to ClickOnce. I created a WinForms application using C# and SQL Server Express. Currently my database is located in the mssql data folder. My connection string is located in an app.config file. <add name="default" providerName="System.Data.SqlClient" connectionString="Server=localhost\SQLEXPRESS;Database=DBase;Trusted_Connection=True;" /> How do I include my database file for it to deploy with the application? To which folder will the database be deployed and will my connection string (above) be still working? You have a couple of options. First, if this is a simple database I

Is it possible to use NGen with ClickOnce deployment?

妖精的绣舞 提交于 2019-11-28 21:17:39
Is it possible to use NGen with ClickOnce deployment? Ron Actually you can use NGEN and clickone, but you are going to need to run the NGEN after the clickonce installation has happened, since NGEN is part of the .NET installation (for 3.5 you should refer to the 2.0 installation). Here is an example, I think it is generic enough for you to use it without changing or doing very little changes to the code (except for the call to your form): static class Program { /// <summary> /// The main entry point for the application. /// </summary> [STAThread] static void Main() { if (ApplicationDeployment

Visual Studio 2010 RTM is not publishing with ClickOnce

血红的双手。 提交于 2019-11-28 20:53:24
问题 Is anyone using ClickOnce with VS2010? I’m getting the following on publish, when the solution builds fine ... Building WindowsFormsApplication1... Error: Cannot publish because a project failed to build. Have tried everything, new clean project (both windforms and WPF), new temporary key, disabled pre-requisites and played with every publish setting. I was hoping it’d be fixed in final, the same thing happened in RC My 'workaround' at the moment is to use msbuild.exe with a clickonce.proj,

ClickOnce - Cannot publish because a project failed to build

会有一股神秘感。 提交于 2019-11-28 20:22:00
When I try to publish my (WPF, C#) application, I get these errors: Cannot publish because a project failed to build. Could not find file 'obj\x86\Debug\MyAPP.exe' I get these errors no matter where from I publish: publish wizard, build menu or right click on project - publish. First it was working ok, but I did the following: I changed the date om my computer to 10/10/2013, I was trying something else. I forgot this and I click build. Then I set the proper date on computer. After that I get these errors. Also every time I click run Visual Studio builds project whether there are changes in

Restart WPF application after click-once update (start the new version)

浪尽此生 提交于 2019-11-28 19:23:34
How to restart WPF application after it has been updated using click-once, i need to start the new version! GoldenTao There are a few ways but most don't work correctly, they end up reopening the old version. It's going to sound crazy that WPF doesn't have a proper way to handle it (#fixwpf), but you'll need to reference System.Windows.Forms.dll and call System.Windows.Forms.Application.Restart(); A quick search found Rob Relyea's post about the same thing (XAML, WPF Microsoft Guy) http://robrelyea.wordpress.com/2007/07/24/application-restart-for-wpf/ It isn't necessary to include the winforms

“Manifest XML signature is not valid” on client machine but works fine on developer computer

浪子不回头ぞ 提交于 2019-11-28 19:16:32
At work we had a ClickOnce application that, when the client would try to install, was throwing the exception: Exception reading manifest from file:/FILEPATH: 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. To solve this, we ended up using another certificate file, and it worked fine (resigned the manifest). But we can not understand why it would work to install the application in the developers machines (even developers that were not working with the application)

How can I prevent launching my app multiple times?

跟風遠走 提交于 2019-11-28 19:15:20
I deployed my C# WinForms application using ClickOnce installation. Everything works fine with it (after a lot of work) :), but now I'm facing a problem: Whenever I click on the application shortcut in the Start menu, a new instance starts. I need to avoid this. What can I do to prevent multiple launches? semao At program startup check if same process is already running: using System.Diagnostics; static void Main(string[] args) { String thisprocessname = Process.GetCurrentProcess().ProcessName; if (Process.GetProcesses().Count(p => p.ProcessName == thisprocessname) > 1) return; } Use this code

IIS - can't access page by ip address instead of localhost

て烟熏妆下的殇ゞ 提交于 2019-11-28 19:12:45
I'm trying to publish ClickOnce application and test it locally. I want to provide installation link so I need to update location with an IP address otherwise I won't be able to install it (because localhost is translated into computer name and it's not accessible). The problem is, that on my IIS I can access my page only by using localhost in the address. http://localhost:9995/publish/Publish.htm <-- working http://192.168.1.104:9995/publish/Publish.htm <-- not working (my IP address) http://my_pc_name:9995/publish/Publish.htm <-- not working http://127.0.0.1:9995/publish/Publish.htm <-- even

How to synchronise the publish version to the assembly version in a .NET ClickOnce application?

…衆ロ難τιáo~ 提交于 2019-11-28 18:37:16
In my C# ClickOnce application, there is an auto-incremented publish version in the Project -> Properties -> Publish tab. I'd like to display that version in my menu Help -> About box, but the code I'm using apparently accesses the assembly Version, which is different. The Assembly Version can be changed manually in the Project -> Properties -> Application -> Assembly Information dialog. So for now, every time before I publish I've been copying the publish version to the assembly version, so my dialog shows the current version of the application. There must be a better way to do this. All I

ClickOnce application replace current installed fliles

泄露秘密 提交于 2019-11-28 17:25:50
With ClickOnce applications, is it possible to replace the current files or install in a different directory when creating a new version? Because the error I get is: Unable to install this application because an application with the same identity is already installed. To install this application, either modify the manifest version for this application or uninstall the preexisting application. As the error message says, there are two options. First, you as a developer should modify the version number of the ClickOnce manifest. This is done at the ClickOnce tab of the project settings. Note that