?
Solved

.NET - Clickonce Update Application, Add "Whats New" Popup

Posted on 2013-11-15
3
Medium Priority
?
541 Views
Last Modified: 2013-11-21
i have a Clickonce application. It posts to an internal server.
if there is a new version, The client applications are asked to update every time the open the program.

I need a form to open with latest changes, or whatever, ONCE after EVERY update, for EACH user

Any Suggestions?
0
Comment
Question by:Ess Kay
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 40

Assisted Solution

by:Jacques Bourgeois (James Burger)
Jacques Bourgeois (James Burger) earned 1000 total points
ID: 39652982
Start the application in a Main method instead of starting it directly in a Form.

Store the current application version somewhere, either in the settings of the application, in a file, in the registry, you name it.

When the application starts, it checks its own version number against the stored number.

If they do not match, then this is an update. In such a case, show the update form with ShowDialog and store the new version number for the next run. When the user closes the update form, display the application startup form.

If the version of the application and the stored version match, then the update form has been displayed once. Simply skip it and go straight to the application startup form.
0
 
LVL 13

Accepted Solution

by:
jonnidip earned 1000 total points
ID: 39655566
You can use this ClickOnce method that shows you if the current deploy has just been installed (so, only on the first run of every update). I am using it to clear local cache when a new update is installed (because the previous cache can contain differences from the actual objects).
System.Deployment.Application.ApplicationDeployment.CurrentDeployment.IsFirstRun

Open in new window

You can simply check it and show your changes file if the value is "true".

Regards.
0
 
LVL 15

Author Closing Comment

by:Ess Kay
ID: 39665813
johnnidip - easiest, but i dont know if it will work if there are multiple users.
james - did not provide details, but ive done something similar which worked.

I save to an xml file onClose, then load it for setting every onLoad of main form.
in the onLoad of my MAIN MDI file, i call this function




  'Whats New
    Public Sub whatsNew()
        Dim assembly__1 As Assembly = Assembly.GetExecutingAssembly()
        Dim fvi As FileVersionInfo = FileVersionInfo.GetVersionInfo(assembly__1.Location)
        Dim version As String = fvi.FileVersion
        If Me.m_Version = version Then
            'No news
        Else
            Me.m_Version = version
            'open whats new
            Dim F As New frmWhatsNew
            F.MdiParent = Me
            F.Show()
        End If
0

Featured Post

PowerShell Core for Advanced Linux Administrators

Understand advanced principals around Powershell Core with a focus on the Linux Administrator.  This course covers how to administer numerous environments across multiple platforms including Linux, Azure, AWS, and Google Cloud from a single shell instance.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The ECB site provides FX rates for major currencies since its inception in 1999 in the form of an XML feed. The files have the following format (reducted for brevity) (CODE) There are three files available HERE (http://www.ecb.europa.eu/stats/exch…
Whether you've completed a degree in computer sciences or you're a self-taught programmer, writing your first lines of code in the real world is always a challenge. Here are some of the most common pitfalls for new programmers.
This is Part 3 in a 3-part series on Experts Exchange to discuss error handling in VBA code written for Excel. Part 1 of this series discussed basic error handling code using VBA. http://www.experts-exchange.com/videos/1478/Excel-Error-Handlin…
In this video, Percona Director of Solution Engineering Jon Tobin discusses the function and features of Percona Server for MongoDB. How Percona can help Percona can help you determine if Percona Server for MongoDB is the right solution for …

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question