---
agentTools:
  projectIndex: https://docs.devmate.com/llms.txt
---

# Configure Updates

\#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 <ApplicationName>.
3. Open the downloaded file in any text editor and use its content as `PublickDSAKey`.

[block:image]
{
  "images": [
    {
      "image": [
        "https://files.readme.io/4d69907-11.png",
        "11.png",
        1012,
        518,
        "#dde3e4"
      ],
      "caption": "Getting PublickDSAKey"
    }
  ]
}
[/block]

[block:callout]
{
  "type": "info",
  "title": "NOTE",
  "body": "A unique `PublickDSAKey` key is also provided by DevMate's Add Application wizard on the Update configuration step."
}
[/block]

\#Adding the Feedback functionality

1. Take the steps described in [Integrate DevMateKit](https://docs.devmate.com/docs/integrate-devmatekit) if you haven't done it yet.

[block:callout]
{
  "type": "info",
  "title": "NOTE",
  "body": "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)."
}
[/block]

2. You can specify additional `DMFrameworkSettings` properties if needed. DevMate Update provides the following configuration options:

[block:parameters]
{
  "data": {
    "h-0": "Property",
    "h-1": "Type",
    "h-2": "Description",
    "0-0": "`IsBeta`",
    "1-0": "`ApplicationIcon`",
    "2-0": "`ActionBeforeStartUpdater`",
    "3-0": "`CheckForBetaUpdates`",
    "4-0": "`CheckForTestUpdates`",
    "5-0": "`CheckForUpdatesAutomatically`",
    "6-0": "`UpdateArguments`",
    "0-1": "bool",
    "1-1": "string",
    "2-1": "Action",
    "3-1": "bool",
    "4-1": "bool",
    "5-1": "bool",
    "6-1": "string",
    "0-2": "Specifies whether a current version of the application is Beta.",
    "1-2": "Sets a “TitleBar” icon for DevMate Framework windows. Must contain at least one 16x16pt icon. Example: *pack://application:,,,/TestApp;component/icon.ico*.",
    "2-2": "Method that is ran right after Updater.exe is started. Can be used for closing the application.",
    "3-2": "If set to “true”, offers to download a beta version of the application.",
    "4-2": "If set to “true”, offers to download a test version of the application.",
    "5-2": "Enables automatic check for updates availability. For more information, read [Configuring Updates API](https://docs.devmate.com/docs/add-update#section-configuring-update-api) (below).",
    "6-2": "Used to add command line arguments when Updater.exe is run."
  },
  "cols": 3,
  "rows": 7
}
[/block]

For example:

[block:code]
{
  "codes": [
    {
      "code": "DMUpdatesFrameworkSettings.UpdateArguments = \"/silent\";\nDMUpdatesFrameworkSettings.CheckForBetaUpdates = true;\nDMUpdatesFrameworkSettings.CheckForTestUpdates = false;\nDMUpdatesFrameworkSettings.CheckForUpdatesAutomatically = true;\nDMUpdatesFrameworkSettings.ActionBeforeStartUpdater = () => App.Current.Shutdown();",
      "language": "csharp"
    }
  ]
}
[/block]

\##Configuring Update API
Use the following code snippet to open the Check for Updates window:

[block:code]
{
  "codes": [
    {
      "code": "DMUpdatesWindow window = new DMUpdatesWindow(); \nwindow.BigIconSource = new BitmapImage(new Uri(\"pack://application:,,,/Images/icon.png\")); \nwindow.ShowDialog();",
      "language": "csharp"
    }
  ]
}
[/block]

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

[block:callout]
{
  "type": "info",
  "title": "NOTE",
  "body": "Checking for updates can be performed if a user selects the “AutoUpdate” option (if `CheckForUpdatesAutomatically` property is set to “true”)."
}
[/block]

[block:code]
{
  "codes": [
    {
      "code": "var updatesFramework = new UpdatesFramework();\nupdatesFramework.AutoCheckUpdate(App.Current.Dispatcher, RunUpdateWindow);\nprivate void RunUpdateWindow(XMLRss xmlRss) \n{\t\t\t\t\n\tDMUpdatesWindow window = new DMUpdatesWindow(xmlRss)\n\twindow.BigIconSource = new BitmapImage(new\n\tUri(“pack://application:,,,/Images/icon.png\"));\n\twindow.ShowDialog();\n}\n",
      "language": "csharp"
    }
  ]
}
[/block]

[block:callout]
{
  "type": "info",
  "body": "You must use 128x128pt icon for the `BigIconSource` property.\nRead [Upload an App to DevMate](https://docs.devmate.com/docs/upload-an-app-to-devmate) to find out more.",
  "title": "NOTE"
}
[/block]