Prerequisites

You’ll need to generate and download a public key from DevMate Dashboard before you can start the integration of DevMate Update. Follow the instructions below to get a public key:

  1. Open your DevMate account and choose Settings > DevMateKit in the left-side pane.
  2. Disclose the Updates Delivery section, choose “DevMate key pair” and then click Download Key for .
  3. Open the downloaded file in any text editor and use its content as PublickDSAKey.
1012

Getting PublickDSAKey

📘

NOTE

A unique PublickDSAKey key is also provided by DevMate's Add Application wizard on the Update configuration step.

Adding the Feedback functionality

  1. Take the steps described in Integrate DevMateKit if you haven't done it yet.

📘

NOTE

You must specify PublickDSAKey to enable the Updates functionality. Your unique key is provided by DevMate's Add Application wizard (available from your DevMate account).

  1. You can specify additional DMFrameworkSettings properties if needed. DevMate Update provides the following configuration options:
PropertyTypeDescription
IsBetaboolSpecifies whether a current version of the application is Beta.
ApplicationIconstringSets a “TitleBar” icon for DevMate Framework windows. Must contain at least one 16x16pt icon. Example: pack://application:,,,/TestApp;component/icon.ico.
ActionBeforeStartUpdaterActionMethod that is ran right after Updater.exe is started. Can be used for closing the application.
CheckForBetaUpdatesboolIf set to “true”, offers to download a beta version of the application.
CheckForTestUpdatesboolIf set to “true”, offers to download a test version of the application.
CheckForUpdatesAutomaticallyboolEnables automatic check for updates availability. For more information, read Configuring Updates API (below).
UpdateArgumentsstringUsed to add command line arguments when Updater.exe is run.

For example:

DMUpdatesFrameworkSettings.UpdateArguments = "/silent";
DMUpdatesFrameworkSettings.CheckForBetaUpdates = true;
DMUpdatesFrameworkSettings.CheckForTestUpdates = false;
DMUpdatesFrameworkSettings.CheckForUpdatesAutomatically = true;
DMUpdatesFrameworkSettings.ActionBeforeStartUpdater = () => App.Current.Shutdown();

Configuring Update API

Use the following code snippet to open the Check for Updates window:

DMUpdatesWindow window = new DMUpdatesWindow(); 
window.BigIconSource = new BitmapImage(new Uri("pack://application:,,,/Images/icon.png")); 
window.ShowDialog();

Use the following code snippet to open the Auto Update Checker window:

📘

NOTE

Checking for updates can be performed if a user selects the “AutoUpdate” option (if CheckForUpdatesAutomatically property is set to “true”).

var updatesFramework = new UpdatesFramework();
updatesFramework.AutoCheckUpdate(App.Current.Dispatcher, RunUpdateWindow);
private void RunUpdateWindow(XMLRss xmlRss) 
{				
	DMUpdatesWindow window = new DMUpdatesWindow(xmlRss)
	window.BigIconSource = new BitmapImage(new
	Uri(“pack://application:,,,/Images/icon.png"));
	window.ShowDialog();
}

📘

NOTE

You must use 128x128pt icon for the BigIconSource property.
Read Upload an App to DevMate to find out more.