Browsed by
Category: Uncategorized

Detect the display mode of your UWP Window

Detect the display mode of your UWP Window

It all started with a request from another UWP developer: “How can I detect if a window is maximized?” The question really took me by surprise and piqued my curiosity, especially since it was coming from a talented UWP developer. First I checked docs.microsoft.com, but to my dismay, nothing, then StackOverflow: nothing, then Google, Bing… no results. This may surprise you, but UWP doesn’t provide an API to detect if a window is maximized. So how can we detect it?…

Read More Read More

What is UWP in 2019?

What is UWP in 2019?

When everything was simple… The first day, Microsoft created UWP, it was great and an easy thing to understand. Alleluia. As a user, if you were able to download the application from the Store and not compatible with Windows 8.1 -> it was an UWP application. As a developer, if you were able (but not mandatory) to target other Windows platforms (Windows 10 mobile, XBox, Surface Hub, Hololens), if the window of your application was based on CoreWindow or if…

Read More Read More

How to automatically generate strongly typed classes for your Resw files

How to automatically generate strongly typed classes for your Resw files

I recently released an open-source extension for Visual Studio 2017 and Visual Studio 2019 adding many highly valuable features to .resw files, including one of the major feature from .resx missing: access to strings via strongly typed static properties. In addition to this feature, ReswPlus also provides: Auto-generation of methods to format your strings Support typed and named parameters, literal strings, string references and Macros Pluralization support (for 196 languages!). Including: support empty states when the number of items is…

Read More Read More

How to open the emoji keyboard/panel in your UWP app

How to open the emoji keyboard/panel in your UWP app

A very small, but interesting advice following a request from another UWP developer! Starting with Windows 10 1709, users are able to open a dedicated Emoji Panel or Picker using the shortcut Windows Key + period (.) or Windows Key + ; Can we open it programmatically? Yes!!! Starting with Windows 10 1809, you can use the following code to open the keyboard and use it in your application:

XboxTools: GameControllerDetector + improved XboxKeyControl

XboxTools: GameControllerDetector + improved XboxKeyControl

I recently released GameControllerDetector (here), a tool allowing developers to detect automatically if a user uses a Xbox gamepad or a media remote on Xbox. I also released XboxKeyControl (v1 here and v2) some months ago, a control allowing developers to display the different keys available on a xbox gamepad or a media remote. Now that we have a way to detect the input device used by a user, we can improve XboxKeyControl to automatically change the glyph displayed when…

Read More Read More

How to detect the media remote on Xbox with UWP

How to detect the media remote on Xbox with UWP

If you write an application on Xbox One with UWP, you are forced to support 2 types of controllers: gamepad and media remote. Unfortunately, a lot of applications don’t fully support the second one with 2 common mistakes: – Some features aren’t accessible with the media remote cause using a button not available (for example, a feature only accessible if the user presses trigger R or Y) – UI isn’t updated to display buttons of the media remote. We will…

Read More Read More

Make Bindings compatible with Multi-Windows.

Make Bindings compatible with Multi-Windows.

When XAML/WinRT was created, applications were only fullscreen, then they became windowed, and recently, more and more applications become multi-windows (Dropbox for example). The main concern with multi-windows app is that it’s very easy to make them crash, due to a limitation of XAML. Why does it crash? Let’s imagine an application with 2 windows (A and B), each window contains a TextBlock element with the Text property binded (using standard or native binding) to the same reference: Artist.FullName. Now…

Read More Read More

How to fix Fiddler when it can’t set the proxy on Windows 10

How to fix Fiddler when it can’t set the proxy on Windows 10

Fiddler is one of my favorite tool, very useful for a developer, but unfortunately, it didn’t work on my new laptop and it was impossible to activate the capture “Failed to register Fiddler as the system proxy”. In order to check if the cause of the issue was Windows or Fiddler, I tried to change the proxy of Internet Explorer and same issue, no way to set the proxy. So if you have the same issue than me, here is…

Read More Read More

XboxKeyControl v2: add a secondary theme

XboxKeyControl v2: add a secondary theme

I’ve recently posted a control I created allowing developers to display Xbox keys on their XAML application. I received some interesting feedback from developers using it, in particular a developer requested me to provide a second theme for this control, using a dark background for buttons (similar to real Xbox gamepad keys) instead of colored backgrounds. Even if I prefer to use colored background (better readiness in my opinion), I get his point and understand why some developers would prefer…

Read More Read More