Change Deployed ClickOnce Application Update Behavior

Hi,

I deployed a VB.NET app using ClickOnce to several users. Right now it is autoupdating itself every time I publish a new version. It checks for updates before launching.

This was ok but now I need to check for updates programatically to show custom user interfaces.

Is it possible to change the update behavior to not check for updates?

Thanks
avvwebAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Jacques Bourgeois (James Burger)PresidentCommented:
I have never used it so I will not be able to help you with it, but there is a System.Deployment.Application namespace that contains classes to program custom upgrade behavior into your ClickOnce application.

I suppose that could have what you need to do what you want.
0
eguilhermeCommented:
check here
http://msdn.microsoft.com/en-us/library/ms404263.aspx

also at the bottom you can find:

Using MageUI.exe to deploy an application that checks for updates programmatically

    Follow the instructions for deploying your application using Mage.exe as explained in Walkthrough: Manually Deploying a ClickOnce Application. On the Deployment Options tab, set the Start Location field to the application manifest ClickOnce should check for updates. On the Update Options tab, clear the This application should check for updates check box.
0
David Johnson, CD, MVPOwnerCommented:
This was ok but now I need to check for updates programatically to show custom user interfaces.

Let me get this straight, you are keeping the version the same but making custom interfaces for different people?

Depending on how you have the presentation logic separated from the program logic you should just be able to add a 'skin' resource to the project which will be on a different distribution schedule.

This is considered forking the project, so you will have to set up new deployment shares and the users will have to start from scratch again.
0
Acronis True Image 2019 just released!

Create a reliable backup. Make sure you always have dependable copies of your data so you can restore your entire system or individual files.

CodeCruiserCommented:
On project properties, goto Publish tab and click on Updates. Then untick the "Application should check for updates" checkbox.


ScreenShot042.jpg
0
avvwebAuthor Commented:
I'm sorry I think I confused the topic a little. Let me elaborate, I HAVE RIGHT NOW an application that uses the auto update capabilities of ClickOnce. I mean whenever I publish a new version, all the clients get automatically updated because I instructed ClickOnce to llok for updates before the application starts.

The thing is that I want to change that behavior on my clients. I want ClickOnce to STOP LOOKING for updates because I want to do it by myself using the above mentioned Namespace.

I'm asking this because I already changed the corresponding settings on my solution in Visual Studio 2010 and published a new version but still the clients are looking for updates before the application starts.

Hope I cleared up the question a little.

Thanks
0
Jacques Bourgeois (James Burger)PresidentCommented:
Then you need a combination of using the classes in the namespace I suggested in your code, combined with unchecking the update CheckBox as CodeCruiser added.

Unchecking the update CheckBox might not work however for applications that are already installed. The users migth need to uninstall and reinstall the application for new Application Updates settings to come into play.
0
avvwebAuthor Commented:
So there is no way to change this setting on installed apps without reinstalling?
0
Jacques Bourgeois (James Burger)PresidentCommented:
Maybe by using the Mage.exe application, mentionned in a previous post.

I understand that Mage enables an administrator to define from the server how updates should behave. But this is administrator stuff, not something I am familiar with, so I am not sure it could do it.
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
avvwebAuthor Commented:
This answer got me on the right track. After a lot of researching I found the way to do it:

1. Locate the certificate your .application and .manifest files are signed with.
2. Make a deploy of a new version to the publishing point of your app.
3. Download to your computer the folder of the app.
4. Open the main and last version .application files with MageUI (Visual Studio Command Prompt).
5. Modify the update settings.
6. Save and sign them (with the correct certificate).
7. Upload the folder again.
8. Open the app and accept the last automatic update.

Thank you!
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Visual Basic.NET

From novice to tech pro — start learning today.