title: C#/Win10 - App notification settings in regedit
body: <p>I'm currently working on a project of my own in C# Windows Forms (Visual Studio 2k17), which mainly will work in background. The project requires in some cases support of Windows 10 built-in notifications to notify the user about certain things that happened (during his work, or during his AFK status).
  What I'm trying to do is to stack up BalloonTips (via ShowBalloonTip function) in Action Center, so they sit there until user clears them manually. In order to do that i have manually tried changing those:</p>
  <p>Windows settings -&gt; Notification &amp; Actions settings -&gt; Notification &amp; actions -&gt; choose my app, which is running in the background -&gt;
  tick to ON : Notifications, Show notification banners, show notifications in action center, play a sound, and change number of notifications visible in action center to 10 / 20, and of course - it worked!</p>
  <p>This &quot;solution&quot; is not that good, because those settings won't be set to proper values that app requires on different computer with Win10.</p>
  <p>I've got an idea now, to change those app notification settings in Windows Settings -&gt; Notifications &amp; Action Center ... via regedit and the usage of proper function in C# (RegistryKey etc). The fuction which sets up registry values properly would be called always at the start of the program. I've found the required registry keys in:</p>
  <p>HKEY_CURRENT_USER -&gt; SOFTWARE -&gt; Microsoft -&gt; Windows -&gt; CurrentVersion -&gt; Notifications -&gt; Settings -&gt; Microsoft.Explorer.Notification.{random-numbers-which-i-don't-know-but-it's-that-app}.</p>
  <p><a href="https://i.stack.imgur.com/tzRW1.png" rel="nofollow noreferrer">Location and look of the registry</a></p>
  <p>Now that you have some background, lets head to my questions</p>
  <ul>
  <li><p>What is proper name of those values, what i call - random numbers (i guess they are some sort of ID of the program)?</p>
  </li>
  <li><p>Is it possible to retrieve those &quot;random-numbers-which-i-dont-know&quot; when running the program? Is there any function to get it in string or sth in C#?</p>
  </li>
  </ul>
  <h1>P.S</h1>
  <p>Apart from the method given above, I've tried couple of other things :</p>
  <ul>
  <li><p>Win 8 functions from Windows.UI and Windows.Data.Xml - ToastNotifications etc. give me System.Runtime errors;</p>
  </li>
  <li><p>Custom functions from several githubs, but they did not stayed in Action Center (yes, im stupid)</p>
  </li>
  <li><p>And of course setting the timer on ShowBalloonTip to 100000000000 ticks, but I know that OS (win 10) has limited it from 5 secs to 30 secs?</p>
  </li>
  </ul>
  <p>Cheers :)</p>