Reader Level:
ARTICLE

Publishing Your Application in VS 2005

Posted by Sivaraman Dhamodaran Articles | Visual C# March 31, 2013
This article explains how do you publish your C# application in a netwrok share and send the update notification to all installed clients.
  • 0
  • 0
  • 2713

Introduction

In this article we will explore publishing a C# application in the network path. The article shows the demonstration steps using the Visual Studio 2005 IDE.

Publishing the application on a shared location has the benefits that the interested consumers go to that location and start installing the published application from that network location. There is no need to cut a CD for each client and ship it to him or her.

Pic01.jpg

In the preceding screen shot, you can see the application developers created an installable setup and published that to a shared location. This shared location can be:

  1. Web Location
  2. An Ftp Site
  3. Network share

Multiple clients with access to the shared location can take the application from the shared location and install it on their local machine. This happens for the first time. For the next time and onward, the publisher of the application publishes the application updates on the same location. When the client starts their application they get the notification of the available update on the published location.

Publishing the application in a shared location is useful and provides benefits for both the publisher and clients subscribed to the published application. In the publisher's point of view, they do not need to cut CDs and ship them to every client. From the client's point of view they will automatically get the update of the application they are using.

In this article we are going to look at:

  1. Publishing the application to a network shared path
  2. Providing the update notification to the client
  3. Pushing the updates forcibly to the installed client location

I am not providing any sample application with this article. You can try this article with any simple C# application on your own.

Publishing the application

To start the publishing wizard, open the project in Visual Studio, then right-click on the project name in the Solution Explorer. From the displayed context menu, select the "Publish" option as in the following:

Pic02.jpg

Then from the wizard, publish the application to a network share. Once the application is published on a network share, the shared location contains a file called publish.htm by default. Clients can access the file in the Internet Explorer using the file protocol as specified below:

File://<YourMachineName>//<Network_ShareName>//Publish.htm

When the user accesses the application in Internet Explorer the page looks like the following:

Pic03.jpg

  1. User navigating to publish location
  2. After reviewing the content, they install the application on their local machine by clicking "Install"

In the video below, I explained the process of publishing the application on the network path, then installing the application by navigating to the published page on the network path.

Video 1 : Explains how do you publish the application.

Publishing the Updates to the Application


Let us say 7 people installed the application from the network published location. Also say the application is modified with many changes to the look and appearance and published to the same location.

In the preceding situation, the software update is placed on the published location. The next time those seven clients start their installed application, they get the notification of the software update from the published location. This notification provides the end user a choice of either updating the application to the new version or skipping the update and using whatever version they have right now.

Click the "Updates" button in the Publish Property Page of the project settings. From the dialog you can specify how you want to provide the update to the end user.

Providing the software updates to all the installed locations via the published location is shown in the following video.

Video 2 : Explains how user gets the Update from the Published location

Sometimes, we may need to push the important updates to the end locations without providing the end user the option to skip this update. The Updates dialog has that option also. Use the third option shown in the following picture to push the major updates to the installed subscribers.

Pic04.jpg

Pushing the update to the end-user is shown in the following video.

Video 3 : Pushing the Major updates to end user machine.

COMMENT USING

Trending up